Examples of Tags


Examples of org.platformlayer.core.model.Tags

    if (networkPoint == null) {
      List<InetAddress> matching = Lists.newArrayList();

      // String privateNetworkId = src.getPrivateNetworkId();
      {
        Tags tags = machine.getTags();
        List<InetAddress> addresses = Tag.NETWORK_ADDRESS.find(tags);

        for (InetAddress address : addresses) {
          if (InetAddressUtils.isPublic(address)) {
            matching.add(address);
View Full Code Here

Examples of org.platformlayer.core.model.Tags

  @Produces({ XML, JSON })
  public Tags listTags() throws RepositoryException {
    boolean fetchTags = true;
    ItemBase managedItem = getManagedItem(fetchTags);

    Tags tags = managedItem.getTags();

    cleanup(tags);
    return tags;
  }
View Full Code Here

Examples of org.platformlayer.core.model.Tags

  @Consumes({ XML, JSON })
  @Produces({ XML, JSON })
  public Tags changeTags(TagChanges changeTags) throws RepositoryException {
    ModelClass<?> modelClass = getModelClass();

    Tags tags = repository.changeTags(modelClass, getProject(), getItemId(), changeTags, null);

    cleanup(tags);
    return tags;
  }
View Full Code Here

Examples of org.rascalmpl.ast.Tags

        return hasMemoization;
    }

    protected Map<String, IValue> parseTags(FunctionDeclaration declaration) {
        final Map<String, IValue> result = new HashMap<String, IValue>();
        Tags tags = declaration.getTags();
        if (tags.hasTags()) {
            for (Tag tag : tags.getTags()) {
                final String key = Names.name(tag.getName());
                result.put(key, tag.accept(new NullASTVisitor<IValue>() {
                    @Override
                    public IValue visitTagDefault(Tag.Default x) {
                        String value = ((TagString.Lexical) x.getContents()).getString();
View Full Code Here

Examples of org.rascalmpl.ast.Tags

    public boolean hasTag(String key) {
        return tags.containsKey(key);
    }

    private static String getScheme(String schemeTag, FunctionDeclaration declaration) {
        Tags tags = declaration.getTags();

        if (tags.hasTags()) {
            for (Tag tag : tags.getTags()) {
                if (Names.name(tag.getName()).equals(schemeTag)) {
                    String contents = ((TagString.Lexical) tag.getContents()).getString();

                    if (contents.length() > 2 && contents.startsWith("{")) {
                        contents = contents.substring(1, contents.length() - 1);
View Full Code Here

Examples of org.rascalmpl.ast.Tags

      throw new JavaCompilation("with classpath [" + config.getRascalJavaClassPathProperty() + "]: " + e.getDiagnostics().getDiagnostics().iterator().next().getMessage(null), vf.sourceLocation(loc));
    }
  }

  private String getClassName(FunctionDeclaration declaration) {
    Tags tags = declaration.getTags();
   
    if (tags.hasTags()) {
      for (Tag tag : tags.getTags()) {
        if (Names.name(tag.getName()).equals(JAVA_CLASS_TAG)) {
          if(tag.hasContents()){
            String contents = ((TagString.Lexical) tag.getContents()).getString();

            if (contents.length() > 2 && contents.startsWith("{")) {
View Full Code Here

Examples of org.xwiki.rest.model.jaxb.Tags

        GetMethod getMethod =
            executeGet(getUriBuilder(PageResource.class).build(getWiki(), TestConstants.TEST_SPACE_NAME,
                TestConstants.TEST_PAGE_NAME).toString());
        Assert.assertEquals(getHttpMethodInfo(getMethod), HttpStatus.SC_OK, getMethod.getStatusCode());

        Tags tags = objectFactory.createTags();
        Tag tag = objectFactory.createTag();
        tag.setName(tagName);
        tags.getTags().add(tag);

        PutMethod putMethod =
            executePutXml(getUriBuilder(PageTagsResource.class).build(getWiki(), TestConstants.TEST_SPACE_NAME,
                TestConstants.TEST_PAGE_NAME).toString(), tags, "Admin", "admin");
        Assert.assertEquals(getHttpMethodInfo(putMethod), HttpStatus.SC_ACCEPTED, putMethod.getStatusCode());

        getMethod =
            executeGet(getUriBuilder(PageTagsResource.class).build(getWiki(), TestConstants.TEST_SPACE_NAME,
                TestConstants.TEST_PAGE_NAME).toString());
        Assert.assertEquals(getHttpMethodInfo(getMethod), HttpStatus.SC_OK, getMethod.getStatusCode());

        tags = (Tags) unmarshaller.unmarshal(getMethod.getResponseBodyAsStream());
        boolean found = false;
        for (Tag t : tags.getTags()) {
            if (tagName.equals(t.getName())) {
                found = true;
                break;
            }
        }
        Assert.assertTrue(found);

        getMethod = executeGet(getUriBuilder(TagsResource.class).build(getWiki()).toString());
        Assert.assertEquals(getHttpMethodInfo(getMethod), HttpStatus.SC_OK, getMethod.getStatusCode());

        tags = (Tags) unmarshaller.unmarshal(getMethod.getResponseBodyAsStream());
        found = false;
        for (Tag t : tags.getTags()) {
            if (tagName.equals(t.getName())) {
                found = true;
                break;
            }
        }
View Full Code Here

Examples of org.xwiki.rest.model.jaxb.Tags

        getMethod =
            executeGet(getUriBuilder(PageTagsResource.class).build(getWiki(), TestConstants.TEST_SPACE_NAME,
                TestConstants.TEST_PAGE_NAME).toString());
        Assert.assertEquals(getHttpMethodInfo(getMethod), HttpStatus.SC_OK, getMethod.getStatusCode());

        Tags tags = (Tags) unmarshaller.unmarshal(getMethod.getResponseBodyAsStream());
        boolean found = false;
        for (Tag t : tags.getTags()) {
            if (tagName.equals(t.getName())) {
                found = true;
                break;
            }
        }
View Full Code Here

Examples of org.xwiki.rest.model.jaxb.Tags

        getMethod =
            executeGet(getUriBuilder(PageTagsResource.class).build(getWiki(), TestConstants.TEST_SPACE_NAME,
                TestConstants.TEST_PAGE_NAME).toString());
        Assert.assertEquals(getHttpMethodInfo(getMethod), HttpStatus.SC_OK, getMethod.getStatusCode());

        Tags tags = (Tags) unmarshaller.unmarshal(getMethod.getResponseBodyAsStream());
        boolean found = false;
        for (Tag t : tags.getTags()) {
            if (tagName.equals(t.getName())) {
                found = true;
                break;
            }
        }
View Full Code Here

Examples of org.zkoss.ztl.Tags

            int b = pkg.indexOf("org.zkoss");
            if (b > 0)
              pkg = pkg.substring(b);
            Class c = Class.forName(pkg
                + f.getName().replace(".class", ""));
            Tags atags = ((Tags) c.getAnnotation(Tags.class));
            if (atags == null)
              continue;
            String keys = atags.tags();
            if (keys == null)
              continue;
            keys = keys.toLowerCase();
            boolean found = true;
            for (String t : tag) {
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.