Examples of Method


Examples of com.insightfullogic.honest_profiler.core.parser.Method

    public void logCollectorShouldCopeWithUnexpectedFrames() {
        final Deque<Profile> found = new ArrayDeque<>();
        final LogCollector collector = new LogCollector(found::add, true);

        for (int i = 0; i < 10; i++) {
            collector.handle(new Method(i, "a", "Bass", "c" + i));
        }

        assertTrue("methods don't cause profiles", found.isEmpty());

        int threadId = 0;
View Full Code Here

Examples of com.jetbrains.php.lang.psi.elements.Method

        Collection<? extends PhpNamedElement> phpNamedElementCollections = phpIndex.getBySignature(originalSignature, null, 0);
        if(phpNamedElementCollections.size() == 0) {
            return Collections.emptySet();
        }

        Method method = (Method) phpNamedElementCollections.iterator().next();
        if (!new Symfony2InterfacesUtil().isObjectRepositoryCall(method)) {
            return Arrays.asList(method);
        }

        // we can also pipe php references signatures and resolve them here
        // overwrite parameter to get string value
        parameter = PhpTypeProviderUtil.getResolvedParameter(phpIndex, parameter);
        if(parameter == null) {
            return phpNamedElementCollections;
        }

        PhpClass phpClass = EntityHelper.resolveShortcutName(project, parameter);
        if(phpClass == null) {
            return phpNamedElementCollections;
        }

        if(method.getName().equals("findAll") || method.getName().equals("findBy")) {
            method.getType().add(phpClass.getFQN() + "[]");
            return phpNamedElementCollections;
        }

        return Arrays.asList(phpClass);
    }
View Full Code Here

Examples of com.mastfrog.acteur.headers.Method

        if (msg instanceof HttpResponse) {
            state.resp = (HttpResponse) msg;
            if (followRedirects) {
                String redirUrl = isRedirect(info, state.resp);
                if (redirUrl != null) {
                    Method meth = state.resp.getStatus().code() == 303 ? Method.GET : Method.valueOf(info.req.getMethod().name());
                    // Shut off events from the old request
                    AtomicBoolean ab = new AtomicBoolean(true);
                    RequestInfo b = new RequestInfo(info.url, info.req, ab, new ResponseFuture(ab), null, info.timeout, info.timer);
                    ctx.channel().attr(HttpClient.KEY).set(b);
                    info.handle.event(new State.Redirect(URL.parse(redirUrl)));
View Full Code Here

Examples of com.rabbitmq.client.Method

  protected ShutdownSignalException channelShutdownSignal() {
    return retryableChannelShutdownSignal();
  }

  protected ShutdownSignalException nonRetryableChannelShutdownSignal() {
    Method m = new AMQP.Channel.Close.Builder().replyCode(404).build();
    return new ShutdownSignalException(false, false, m, null);
  }
View Full Code Here

Examples of com.redhat.ceylon.compiler.typechecker.model.Method

    @Override
    public void visit(final Tree.MethodDefinition that) {
        //Don't even bother with nodes that have errors
        if (errVisitor.hasErrors(that))return;
        final Method d = that.getDeclarationModel();
        if (!((opts.isOptimize() && d.isClassOrInterfaceMember()) || isNative(d))) {
            comment(that);
            initDefaultedParameters(that.getParameterLists().get(0), d);
            FunctionHelper.methodDefinition(that, this, true);
            //Add reference to metamodel
            out(names.name(d), ".$crtmm$=");
View Full Code Here

Examples of com.stuffwithstuff.magpie.Method

  public static void execute(String path) throws IOException {
    String script = MagpieAppHost.readFile(path);
    Magpie magpie = new Magpie(new MagpieAppHost());
   
    magpie.defineMethod("printString(s is String)",
        "Prints the given string to stdout.", new Method() {
      public Object call(Object left, Object right) {
        System.out.print(right);
        return null;
      }
    });
View Full Code Here

Examples of com.sun.jdi.Method

            List<Method> list = classType.methodsByName( "onBreak" );
            if list.size() == 0 ) {
                throw new IllegalStateException( "MVELDebugHandler.onBreak cannot be found by JDI" );
            }
           
            Method method = list.get( 0 );
            if (method != null && !method.isNative()) {
                Location location = method.location();
                if (location != null && location.codeIndex() != -1) {
                    req = getEventRequestManager().createBreakpointRequest(location);
                    req.addThreadFilter( ((ClassPrepareEvent) event).thread() );
                    req.setSuspendPolicy( EventRequest.SUSPEND_ALL  );
                } else {
View Full Code Here

Examples of com.sun.org.apache.bcel.internal.classfile.Method

            null, cpg.getConstantPool()));
    dups.add(varRef);
      }
  }

  Method init = compileInit(sortObjects, sortRecord,
           cpg, className);
  Method extract = compileExtract(sortObjects, sortRecord,
          cpg, className);
  sortRecord.addMethod(init);
  sortRecord.addMethod(extract);

  xsltc.dumpClass(sortRecord.getJavaClass());
View Full Code Here

Examples of com.sun.research.ws.wadl.Method

     * @param m
     * @return the enhanced {@link Method}
     * @see com.sun.jersey.server.wadl.WadlGenerator#createMethod(com.sun.jersey.api.model.AbstractResource, com.sun.jersey.api.model.AbstractResourceMethod)
     */
    public Method createMethod( AbstractResource r, AbstractResourceMethod m ) {
        final Method result = _delegate.createMethod( r, m );
        final MethodDocType methodDoc = _resourceDoc.getMethodDoc( r.getResourceClass(), m.getMethod() );
        if ( methodDoc != null && !isEmpty( methodDoc.getCommentText() ) ) {
            final Doc doc = new Doc();
            doc.getContent().add( methodDoc.getCommentText() );
            // doc.getOtherAttributes().put( new QName( "xmlns" ), "http://www.w3.org/1999/xhtml" );
            result.getDoc().add( doc );
        }
        return result;
    }
View Full Code Here

Examples of com.sun.tools.classfile.Method

    void verifyBytecode(VarargsMethod selected) {
        bytecodeCheckCount++;
        File compiledTest = new File("Test.class");
        try {
            ClassFile cf = ClassFile.read(compiledTest);
            Method testMethod = null;
            for (Method m : cf.methods) {
                if (m.getName(cf.constant_pool).equals("test")) {
                    testMethod = m;
                    break;
                }
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.