All Downloads are FREE. Search and download functionalities are using the official Maven repository.

br.com.objectos.code.MethodInfoFake Maven / Gradle / Ivy

/*
 * Copyright 2014 Objectos, Fábrica de Software LTDA.
 *
 * 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 br.com.objectos.code;

/**
 * @author [email protected] (Marcio Endo)
 */
public class MethodInfoFake {

  public static final MethodInfo ANNOTATED_ANNOTATED_METHOD = builder()
      .name("annotatedMethod")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.VOID)
      .annotationInfo(AnnotationInfoFake.METHOD_ANNOTATION)
      .build();
  public static final MethodInfo ANNOTATED_ANNOTATED_PARAMETER = builder()
      .name("annotatedParameter")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.VOID)
      .parameterInfo(ParameterInfoFake.INT_ID_0_2)
      .parameterInfo(ParameterInfoFake.STRING_NAME_ANNOTATED)
      .build();
  public static final MethodInfo ANNOTATED_NOT_NULL = builder()
      .name("notNull")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.VOID)
      .parameterInfo(ParameterInfoFake.OBJECT_NOT_NULL)
      .build();

  public static final MethodInfo GENERIC_GET_STRING_LIST = builder()
      .name("getStringList")
      .accessInfo(AccessInfo.DEFAULT)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.LIST_STRING)
      .build();
  public static final MethodInfo GENERIC_RAW_LIST = builder()
      .name("rawList")
      .accessInfo(AccessInfo.DEFAULT)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.LIST_ANY)
      .build();
  public static final MethodInfo GENERIC_HAS_ANY = builder()
      .name("hasAny")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .parameterInfo(ParameterInfoFake.SET_STRING_NAMESET)
      .build();
  public static final MethodInfo GENERIC_IS_PRESENT = builder()
      .name("isPresent")
      .accessInfo(AccessInfo.DEFAULT)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .parameterInfo(ParameterInfoFake.OPTIONAL_ANY_EXTENDS_GENERIC)
      .build();
  public static final MethodInfo GENERIC_ID = builder()
      .name("id")
      .accessInfo(AccessInfo.DEFAULT)
      .returnTypeInfo(SimpleTypeInfoFake.VOID)
      .parameterInfo(ParameterInfoFake.INT_ID)
      .build();

  public static final MethodInfo POJO_ACTIVE = builder()
      .name("active")
      .accessInfo(AccessInfo.DEFAULT)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .build();
  public static final MethodInfo POJO_ARRAY = builder()
      .name("array")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.VOID)
      .parameterInfo(ParameterInfoFake.STRING_ARRAY)
      .build();

  public static final MethodInfo POJO_ARRAY_RETURN_ARRAY_INT = builder()
      .name("returnArrayInt")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.INT_ARRAY)
      .build();
  public static final MethodInfo POJO_ARRAY_RETURN_ARRAY_STRING = builder()
      .name("returnArrayString")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.STRING_ARRAY)
      .build();
  public static final MethodInfo POJO_ARRAY_PARAMETER_ARRAY_INT = builder()
      .name("parameterInt")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.VOID)
      .parameterInfo(ParameterInfoFake.INT_ARRAY_I)
      .build();
  public static final MethodInfo POJO_ARRAY_PARAMETER_ARRAY_STRING = builder()
      .name("parameterString")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.VOID)
      .parameterInfo(ParameterInfoFake.STRING_ARRAY_S)
      .build();

  public static final MethodInfo POJO_DATE = builder()
      .name("date")
      .accessInfo(AccessInfo.DEFAULT)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.LOCAL_DATE__)
      .build();
  public static final MethodInfo POJO_DO_NOTHING = builder()
      .name("doNothing")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypePrimitives.VOID)
      .build();
  public static final MethodInfo POJO_GET_TOTAL = builder()
      .name("getTotal")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.DOUBLE)
      .parameterInfo(ParameterInfoFake.LOCAL_DATE_DATE)
      .build();
  public static final MethodInfo POJO_IS_VALID = builder()
      .name("isValid")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .build();
  public static final MethodInfo POJO_LAST_NAME = builder()
      .name("lastName")
      .accessInfo(AccessInfo.DEFAULT)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.STRING)
      .build();
  public static final MethodInfo POJO_LIST_OF_SELF = builder()
      .name("listOfSelf")
      .accessInfo(AccessInfo.PROTECTED)
      .returnTypeInfo(SimpleTypeInfoFake.LIST_POJO)
      .build();
  public static final MethodInfo POJO_NAME = builder()
      .name("name")
      .accessInfo(AccessInfo.DEFAULT)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.STRING)
      .build();
  public static final MethodInfo POJO_SELF = builder()
      .name("self")
      .accessInfo(AccessInfo.PROTECTED)
      .returnTypeInfo(SimpleTypeInfoFake.POJO)
      .build();
  public static final MethodInfo POJO_VALUE = builder()
      .name("value")
      .accessInfo(AccessInfo.DEFAULT)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.DOUBLE)
      .build();
  public static final MethodInfo POJO_VARARGS_MIXED = builder()
      .name("varargsMixed")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.VOID)
      .parameterInfo(ParameterInfoFake.OBJECT_FIRST)
      .parameterInfo(ParameterInfoFake.OBJECT_ARRAY_VARARGS_1_2)
      .varargs()
      .build();
  public static final MethodInfo POJO_VARARGS_ONLY = builder()
      .name("varargsOnly")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.VOID)
      .parameterInfo(ParameterInfoFake.OBJECT_ARRAY_VARARGS)
      .varargs()
      .build();

  public static final MethodInfo POJO_GENERIC_TESTABLE_IS_EQUAL = builder()
      .name("isEqual")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .parameterInfo(ParameterInfoFake.POJO_GENERIC_RAW_ARG)
      .build();
  public static final MethodInfo POJO_GENERIC_GET_VALUE = builder()
      .name("getValue")
      .accessInfo(AccessInfo.DEFAULT)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.T)
      .build();

  public static final MethodInfo POJO_INTERFACE_EQUALS = builder()
      .name("equals")
      .accessInfo(AccessInfo.PUBLIC)
      .parameterInfo(ParameterInfoFake.OBJECT_OBJ)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .build();
  public static final MethodInfo POJO_INTERFACE_GET_SOUND = builder()
      .name("getSound")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.INT)
      .build();
  public static final MethodInfo POJO_INTERFACE_HASHCODE = builder()
      .name("hashCode")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.NATIVE)
      .returnTypeInfo(SimpleTypeInfoFake.INT)
      .build();
  public static final MethodInfo POJO_INTERFACE_TO_STRING = builder()
      .name("toString")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.STRING)
      .build();
  public static final MethodInfo POJO_INTERFACE_TURN_OFF = builder()
      .name("turnOff")
      .accessInfo(AccessInfo.PUBLIC)
      .parameterInfo(ParameterInfoFake.LOCAL_DATE_DATE)
      .returnTypeInfo(SimpleTypeInfoFake.INT)
      .build();
  public static final MethodInfo POJO_INTERFACE_TURN_ON = builder()
      .name("turnOn")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .build();
  public static final MethodInfo POJO_INTERFACE_TURN_UP = builder()
      .name("turnUp")
      .accessInfo(AccessInfo.PUBLIC)
      .parameterInfo(ParameterInfoFake.LOCAL_DATE_DATE_0_2)
      .parameterInfo(ParameterInfoFake.INT_AMMOUNT_1_2)
      .returnTypeInfo(SimpleTypeInfoFake.VOID)
      .build();

  public static final MethodInfo POJO_SUBCLASS_ACTIVE = builder()
      .name("active")
      .accessInfo(AccessInfo.DEFAULT)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .build();
  public static final MethodInfo POJO_SUBCLASS_IMPORT_INNER_CLASS = builder()
      .name("importInnerClass")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.VOID)
      .parameterInfo(ParameterInfoFake.POJO_INNER_INNER)
      .build();
  public static final MethodInfo POJO_SUBCLASS_INHERITED = builder()
      .name("inherited")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .build();
  public static final MethodInfo POJO_SUBCLASS_LAST_NAME = builder()
      .name("lastName")
      .accessInfo(AccessInfo.DEFAULT)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.STRING)
      .build();
  public static final MethodInfo POJO_SUBCLASS_SELF = builder()
      .name("self")
      .accessInfo(AccessInfo.PROTECTED)
      .returnTypeInfo(SimpleTypeInfoFake.POJO_SUBCLASS)
      .annotationInfo(AnnotationInfoFake.OVERRIDE)
      .build();

  public static final MethodInfo POJO_SUB_SUBCLASS_MIDDLE_NAME = builder()
      .name("middleName")
      .accessInfo(AccessInfo.DEFAULT)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.STRING)
      .build();

  public static final MethodInfo SIMPLE_IS_LATE = builder()
      .name("isLate")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .parameterInfo(ParameterInfoFake.LOCAL_DATE_DATE)
      .annotationInfo(AnnotationInfoFake.AUTO_FUNCTIONAL)
      .build();
  public static final MethodInfo SIMPLE_IS_OPEN = builder()
      .name("isOpen")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .annotationInfo(AnnotationInfoFake.AUTO_FUNCTIONAL)
      .build();
  public static final MethodInfo SIMPLE_TO_DATE = builder()
      .name("toDate")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.LOCAL_DATE__)
      .annotationInfo(AnnotationInfoFake.AUTO_FUNCTIONAL)
      .build();
  public static final MethodInfo SIMPLE_TO_DOUBLE_VALUE = builder()
      .name("toDoubleValue")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.DOUBLE)
      .annotationInfo(AnnotationInfoFake.AUTO_FUNCTIONAL)
      .build();
  public static final MethodInfo SIMPLE_TO_GENERIC = builder()
      .name("toGeneric")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.SET_STRING)
      .parameterInfo(ParameterInfoFake.ITERABLE_ANY_EXTENDS_SIMPLE_ITERABLE)
      .annotationInfo(AnnotationInfoFake.AUTO_FUNCTIONAL)
      .build();

  public static final MethodInfo SOURCE_FILE_IS_EQUAL = builder()
      .name("isEqual")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .parameterInfo(ParameterInfoFake.SOURCE_FILE_THAT)
      .build();
  public static final MethodInfo SOURCE_FILE_TO_STRING = builder()
      .name("toString")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.STRING)
      .build();
  public static final MethodInfo SOURCE_FILE_TESTABLE_IS_EQUAL = builder()
      .name("isEqual")
      .accessInfo(AccessInfo.PUBLIC)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .parameterInfo(ParameterInfoFake.SOURCE_FILE_ARG)
      .build();

  public static final MethodInfo SIMPLE_BUILDER_STEP0 = builder()
      .name("step0")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.SIMPLE_BUILDER_STEP0)
      .parameterInfo(ParameterInfoFake.STRING_STEP0)
      .build();
  public static final MethodInfo SIMPLE_BUILDER_STEP0_STEP1 = builder()
      .name("step1")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.SIMPLE_BUILDER_STEP1)
      .parameterInfo(ParameterInfoFake.BOOLEAN_STEP1)
      .build();
  public static final MethodInfo SIMPLE_BUILDER_STEP1_BUILD = builder()
      .name("build")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.STRING)
      .build();

  public static final MethodInfo TESTABLE_IS_EQUAL_TO = builder()
      .name("isEqualTo")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.EQUALITY)
      .parameterInfo(ParameterInfoFake.OBJECT_ARG)
      .build();

  public static final MethodInfo _TARGET = builder()
      .name("target")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.VOID)
      .build();
  public static final MethodInfo _TARGET__GET = builder()
      .name("getTarget")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.STRING)
      .build();
  public static final MethodInfo _TARGET__IS = builder()
      .name("isTarget")
      .accessInfo(AccessInfo.PUBLIC)
      .modifierInfo(ModifierInfo.ABSTRACT)
      .returnTypeInfo(SimpleTypeInfoFake.BOOLEAN)
      .build();

  private MethodInfoFake() {
  }

  private static MethodInfoFakeBuilder builder() {
    return new MethodInfoFakeBuilder();
  }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy