Examples of MethodList


Examples of com.android.dx.cf.iface.MethodList

        classDeps.getMethodDeps("INTERFACES").addDependency(Util.parseClassName(interfaces.getType(i).getClassName()).toString(), "");
      }
    }

    // Methods
    MethodList methods= classFile.getMethods();
    for (int i= 0; i < methods.size(); i++)
    {
      Method method= methods.get(i);
      // CstMethodRef methodRef = new
      // CstMethodRef(method.getDefiningClass(), method.getNat());
      // We shouldn't need to go through the signature. If the class is
      // not used in the code block, we can ignore it.
      // processSignature(methodRef, dependencies);
View Full Code Here

Examples of com.android.dx.cf.iface.MethodList

     * @param out {@code non-null;} output class
     */
    private static void processMethods(DirectClassFile cf,
            CfOptions args, ClassDefItem out) {
        CstType thisClass = cf.getThisClass();
        MethodList methods = cf.getMethods();
        int sz = methods.size();

        for (int i = 0; i < sz; i++) {
            Method one = methods.get(i);
            try {
                CstMethodRef meth = new CstMethodRef(thisClass, one.getNat());
                int accessFlags = one.getAccessFlags();
                boolean isStatic = AccessFlags.isStatic(accessFlags);
                boolean isPrivate = AccessFlags.isPrivate(accessFlags);
View Full Code Here

Examples of com.android.dx.cf.iface.MethodList

     * {@code AnnotationDefault} annotation, if there were any
     * annotation defaults in the class, or {@code null} if not
     */
    private static Annotation translateAnnotationDefaults(DirectClassFile cf) {
        CstType thisClass = cf.getThisClass();
        MethodList methods = cf.getMethods();
        int sz = methods.size();
        Annotation result =
            new Annotation(thisClass, AnnotationVisibility.EMBEDDED);
        boolean any = false;

        for (int i = 0; i < sz; i++) {
            Method one = methods.get(i);
            AttributeList attribs = one.getAttributes();
            AttAnnotationDefault oneDefault = (AttAnnotationDefault)
                attribs.findFirst(AttAnnotationDefault.ATTRIBUTE_NAME);

            if (oneDefault != null) {
View Full Code Here

Examples of com.android.dx.cf.iface.MethodList

  {
    boolean skeletonOnly= hasAnnotation(cf.getAttributes(), XMLVMSkeletonOnly.class);
    Element classElement= processClass(cf, root, referencedTypes);
    processFields(cf.getFields(), classElement, referencedTypes, skeletonOnly);

    MethodList methods= cf.getMethods();
    int sz= methods.size();

    for (int i= 0; i < sz; i++)
    {
      Method one= methods.get(i);

      if (hasAnnotation(one.getAttributes(), XMLVMIgnore.class))
      {
        // If this method has the @XMLVMIgnore annotation, we just
        // simply ignore it.
View Full Code Here

Examples of com.strobel.reflection.MethodList

        }
    }

    static MethodInfo getInvokeMethod(final Expression expression) {
        final Type interfaceType = expression.getType();
        final MethodList methods = interfaceType.getMethods();

        if (!interfaceType.isInterface() || methods.size() != 1) {
            throw Error.expressionTypeNotInvokable(interfaceType);
        }

        return methods.get(0);
    }
View Full Code Here

Examples of com.strobel.reflection.MethodList

        final ParameterExpressionList parameters) {

        VerifyArgument.notNull(interfaceType, "interfaceType");
        verifyCanRead(body, "body");

        final MethodList methods = interfaceType.getMethods(BindingFlags.PublicInstance);

        if (!interfaceType.isInterface() || methods.size() != 1) {
            throw Error.lambdaTypeMustBeSingleMethodInterface();
        }

        final MethodInfo method = methods.get(0);
        final ParameterList methodParameters = method.getParameters();

        if (methodParameters.size() > 0) {
            if (parameters.size() != methodParameters.size()) {
                throw Error.incorrectNumberOfLambdaArguments();
View Full Code Here

Examples of com.strobel.reflection.MethodList

    private void writeAnnotation(final AnnotationBuilder<? extends Annotation> a) {
        _dataBuffer.putShort(_typeBuilder.getUtf8StringToken(a.getAnnotationType().getSignature()));
        _dataBuffer.putShort(a.getValues().size());

        final MethodList attributes = a.getAttributes();
        final ReadOnlyList<Object> values = a.getValues();

        for (int i = 0, n = attributes.size(); i < n; i++) {
            final MethodInfo attribute = attributes.get(i);
            _dataBuffer.putShort(_typeBuilder.getUtf8StringToken(attribute.getName()));
            writeAttributeType(values.get(i));
        }
    }
View Full Code Here

Examples of com.strobel.reflection.MethodList

            throw Error.annotationHasNoDefaultAttribute();
        }

        checkProperties(
            annotationType,
            new MethodList(valueProperty),
            new ReadOnlyList<>(value)
        );

        return new AnnotationBuilder<>(
            annotationType,
            new MethodList(valueProperty),
            new ReadOnlyList<>(value)
        );
    }
View Full Code Here

Examples of com.strobel.reflection.MethodList

                throw Error.expressionTypeNotInvokable(interfaceType);
            }
            return null;
        }

        final MethodList methods = interfaceType.getMethods();

        MethodInfo invokeMethod = null;

        for (final MethodInfo method : methods) {
            if (method.isDefault()) {
View Full Code Here

Examples of com.sun.jersey.core.reflection.MethodList

            }
            oClass = oClass.getSuperclass();
        }

        MethodList ml = new MethodList(c.getMethods());
        int methodIndex = 0;
        for (AnnotatedMethod m : ml.
                hasNotMetaAnnotation(HttpMethod.class).
                hasNotAnnotation(Path.class).
                hasNumParams(1).
                hasReturnType(void.class).
                nameStartsWith("set")) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.