Package org.chromium.sdk.internal.protocolparser

Examples of org.chromium.sdk.internal.protocolparser.JsonSubtypeCondition


          scope.startLine("  " + resultRef + " = false;\n");
          scope.startLine("}\n");
        }
      });
    }
    JsonSubtypeCondition conditionAnn = m.getAnnotation(JsonSubtypeCondition.class);
    if (conditionAnn != null) {
      int savedResSize = results.size();
      if (conditionAnn.fieldIsAbsent()) {
        results.add(new FieldConditionLogic(false) {
          @Override
          boolean checkValue(boolean hasValue, Object unparsedValue, QuickParser<?> parser) {
            return !hasValue;
          }

          @Override
          void writeCheckJava(MethodScope scope, String valueRef, String hasValueRef,
              String resultRef, QuickParser<?> quickParser) {
            scope.startLine("boolean " + resultRef + " = !" + hasValueRef + ";\n");
          }
        });
      }
      if (conditionAnn.valueIsNull()) {
        results.add(new FieldConditionLogic(false) {
          @Override
          boolean checkValue(boolean hasValue, Object unparsedValue, QuickParser<?> parser) {
            return hasValue && unparsedValue != null;
          }
View Full Code Here

TOP

Related Classes of org.chromium.sdk.internal.protocolparser.JsonSubtypeCondition

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.