Examples of StringTag


Examples of org.jmule.core.edonkey.packet.tag.StringTag

   */
  public static Packet getServerLoginPacket(UserHash userHash, int clientPort,
      String userNickName) throws JMException {
   
    TagList tagList = new TagList();
    tagList.addTag(new StringTag(TAG_NAME_NAME, userNickName));
    tagList.addTag(new IntTag(TAG_NAME_PROTOCOLVERSION,ProtocolVersion ));
    tagList.addTag(new IntTag(TAG_NAME_CLIENTVER, ServerSoftwareVersion));
    tagList.addTag(new IntTag(TAG_NAME_FLAGS, SUPPORTED_FLAGS));
    tagList.addTag(new IntTag(TAG_NAME_UDP_PORT, ConfigurationManagerSingleton.getInstance().getUDP()));
 
View Full Code Here

Examples of org.jmule.core.edonkey.packet.tag.StringTag

       
    int misc_optins1 = Utils.peerFeatures1ToInt(clientFeatures);
    int misc_optins2 = Utils.peerFeatures2ToInt(clientFeatures);
   
    TagList tagList = new TagList();
    tagList.addTag(new StringTag(TAG_NAME_NAME, userName));
    tagList.addTag(new IntTag(TAG_NAME_MISC_OPTIONS1,misc_optins1 ));
    tagList.addTag(new IntTag(TAG_NAME_MISC_OPTIONS2,misc_optins2));
   
    tagList.addTag(new IntTag(TAG_NAME_PROTOCOLVERSION,ProtocolVersion ));
    tagList.addTag(new IntTag(TAG_NAME_CLIENTVER, E2DKConstants.getSoftwareVersion()));
View Full Code Here

Examples of org.jmule.core.edonkey.packet.tag.StringTag

      throws JMException {

    int misc_optins1 = Utils.peerFeatures1ToInt(clientFeatures);
    int misc_optins2 = Utils.peerFeatures2ToInt(clientFeatures);
    TagList tagList = new TagList();
    tagList.addTag(new StringTag(TAG_NAME_NAME, userName));
    tagList.addTag(new IntTag(TAG_NAME_MISC_OPTIONS1, misc_optins1));
    tagList.addTag(new IntTag(TAG_NAME_MISC_OPTIONS2, misc_optins2));

    tagList.addTag(new IntTag(TAG_NAME_PROTOCOLVERSION, ProtocolVersion));
    tagList.addTag(new IntTag(TAG_NAME_CLIENTVER, E2DKConstants.getSoftwareVersion()));
View Full Code Here

Examples of org.jmule.core.edonkey.packet.tag.StringTag

          Int128 id = new Int128(hash);

          if (!publisher.isPublishingSource(id)) {
            filesToPublish++;
            List<Tag> tagList = new LinkedList<Tag>();
            tagList.add(new StringTag(TAG_FILENAME, file
                .getSharingName()));
            tagList.add(new IntTag(TAG_FILESIZE, (int) file
                .length()));
            tagList
                .add(new IntTag(TAG_SOURCEIP,
                    org.jmule.core.utils.Convert
                        .byteToInt(getIPAddress()
                            .getAddress())));
            try {
              tagList.add(new IntTag(TAG_SOURCEPORT,
                  config_manager.getTCP()));
            } catch (ConfigurationManagerException e) {
              e.printStackTrace();
            }

            publisher.publishSource(id, tagList);
          }
          if (!publisher.isPublishingKeyword(id)) {
            filesToPublish++;
            List<Tag> tagList = new LinkedList<Tag>();
            tagList.add(new StringTag(TAG_FILENAME, file
                .getSharingName()));
            tagList.add(new IntTag(TAG_FILESIZE, (int) file
                .length()));

            publisher.publishKeyword(id, tagList);
          }

          if (file.getTagList().hasTag(TAG_FILERATING))
            if (!publisher.isPublishingNote(id)) {
              filesToPublish++;
              List<Tag> tagList = new LinkedList<Tag>();
              tagList.add(new StringTag(TAG_FILENAME, file
                  .getSharingName()));
              tagList.add(new IntTag(TAG_FILESIZE, (int) file
                  .length()));
              tagList.add(new IntTag(TAG_FILERATING, file
                  .getFileQuality().getAsInt()));
View Full Code Here

Examples of org.jmule.core.edonkey.packet.tag.StringTag

    return tmpFileName;
  }
 
  public void setTempFileName(String tempFileName) {
    this.tagList.removeTag(FT_TEMPFILE);
    Tag tag = new StringTag(FT_TEMPFILE, tempFileName);
    tagList.addTag(tag);
  }
View Full Code Here

Examples of org.jmule.core.edonkey.packet.tag.StringTag

    return realFileName;
  }
 
  public void setRealFileName(String realFileName) {
    this.tagList.removeTag(FT_FILENAME);
    Tag tag = new StringTag(FT_FILENAME, realFileName);
    tagList.addTag(tag);
  }
View Full Code Here

Examples of org.jmule.core.edonkey.packet.tag.StringTag

  }
 
  private void init() {
    String fileName = this.getSharingName();
    if (fileName==null) fileName = file.getName();
    Tag tag = new StringTag(FT_FILENAME, fileName);
    tagList.addTag(tag);

    tag = new IntTag(FT_FILESIZE, Convert.longToInt(file.length()));
    tagList.addTag(tag);
  }
View Full Code Here

Examples of se.llbit.nbt.StringTag

      AnyTag playerTag = result.get(".Data.Player");

      System.out.println("writing output to "+outFn);
      DataOutputStream out = new DataOutputStream(new GZIPOutputStream(new FileOutputStream(outFn)));
      NamedTag rootTag = new NamedTag(new StringTag(""), (CompoundTag) playerTag);
      rootTag.write(out);
      out.close();
      System.out.println("done");
    } catch (FileNotFoundException e) {
      // TODO Auto-generated catch block
View Full Code Here

Examples of soot.tagkit.StringTag

            Scene.v().setPointsToAnalysis(onDemandAnalysis);
        }
    }
   
    protected void addTags( PAG pag ) {
        final Tag unknown = new StringTag( "Untagged Spark node" );
        final Map<Node, Tag> nodeToTag = pag.getNodeTags();
        for( Iterator cIt = Scene.v().getClasses().iterator(); cIt.hasNext(); ) {
            final SootClass c = (SootClass) cIt.next();
            for( Iterator mIt = c.methodIterator(); mIt.hasNext(); ) {
                SootMethod m = (SootMethod) mIt.next();
View Full Code Here

Examples of soot.tagkit.StringTag

    }
  }
 
  public void tag(ValueBox box, String message) {
    Stmt stmt = boxStmtMap.get(box);
    stmt.addTag(new StringTag(message));
  }
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.