Package net.bnubot.core

Examples of net.bnubot.core.BNetUser


    assertEquals(u.getFullLogonName(), "testuser#2@USEast");
    assertEquals(u.getFullAccountName(), "testuser@USEast");
  }

  public void testDifferentRealmWithNumber() {
    BNetUser u = new BNetUser("testuser@Azeroth#2", "someone@USEast");
    assertEquals(u.getShortLogonName(), "testuser#2@Azeroth");
    assertEquals(u.getFullLogonName(), "testuser#2@Azeroth");
    assertEquals(u.getFullAccountName(), "testuser@Azeroth");
  }
View Full Code Here


    assertEquals(u.getFullLogonName(), "testuser#2@Azeroth");
    assertEquals(u.getFullAccountName(), "testuser@Azeroth");
  }

  public void testDifferentRealmWithBothNumbers() {
    BNetUser u = new BNetUser("testuser#2@Azeroth", "someone#2@USEast");
    assertEquals(u.getShortLogonName(), "testuser#2@Azeroth");
    assertEquals(u.getFullLogonName(), "testuser#2@Azeroth");
    assertEquals(u.getFullAccountName(), "testuser@Azeroth");
  }
View Full Code Here

    assertEquals(u.getFullLogonName(), "testuser#2@Azeroth");
    assertEquals(u.getFullAccountName(), "testuser@Azeroth");
  }

  public void testSameRealmWithBothNumbers() {
    BNetUser u = new BNetUser("testuser#2@USEast", "someone#2@USEast");
    assertEquals(u.getShortLogonName(), "testuser#2");
    assertEquals(u.getFullLogonName(), "testuser#2@USEast");
    assertEquals(u.getFullAccountName(), "testuser@USEast");
  }
View Full Code Here

    assertEquals(u.getFullLogonName(), "testuser#2@USEast");
    assertEquals(u.getFullAccountName(), "testuser@USEast");
  }

  public void testSameRealmWithNumber2() {
    BNetUser u = new BNetUser("testuser@USEast", "someone#2@USEast");
    assertEquals(u.getShortLogonName(), "testuser");
    assertEquals(u.getFullLogonName(), "testuser@USEast");
    assertEquals(u.getFullAccountName(), "testuser@USEast");
  }
View Full Code Here

        //  is.readDWord();  // Account number (defunct)
        //  is.readDWord(); // Registration authority (defunct)
          String username = is.readNTString();
          String text = is.readNTString();

          BNetUser user = null;
          switch(eid) {
          case BNCSChatEventIDs.EID_SHOWUSER:
          case BNCSChatEventIDs.EID_USERFLAGS:
          case BNCSChatEventIDs.EID_JOIN:
          case BNCSChatEventIDs.EID_LEAVE:
          case BNCSChatEventIDs.EID_TALK:
          case BNCSChatEventIDs.EID_EMOTE:
          case BNCSChatEventIDs.EID_WHISPERSENT:
          case BNCSChatEventIDs.EID_WHISPER:
            switch(productID) {
            case ProductIDs.PRODUCT_D2DV:
            case ProductIDs.PRODUCT_D2XP:
              int asterisk = username.indexOf('*');
              if(asterisk >= 0)
                username = username.substring(asterisk+1);
              break;
            }
           
            user = BNetUser.getBNetUser(username, cs.myRealm);
            user.setFlags(flags);
            user.setPing(ping);
            break;
          }
         
          switch(eid) {
          case BNCSChatEventIDs.EID_SHOWUSER:
View Full Code Here

TOP

Related Classes of net.bnubot.core.BNetUser

Copyright © 2018 www.massapicom. 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.