Esempio n. 1
0
  /** See TS 51.011 10.5.10 */
  @DSGenerator(
      tool_name = "Doppelganger",
      tool_version = "2.0",
      generated_on = "2013-12-30 12:59:17.042 -0500",
      hash_original_method = "D43EB4B47E694B53E14D637B6CBB15DA",
      hash_generated_method = "7FE5675D2A5F80229B9CC32689C8E510")
  public void appendExtRecord(byte[] extRecord) {
    try {
      if (extRecord.length != EXT_RECORD_LENGTH_BYTES) {
        return;
      }

      if ((extRecord[0] & EXT_RECORD_TYPE_MASK) != EXT_RECORD_TYPE_ADDITIONAL_DATA) {
        return;
      }

      if ((0xff & extRecord[1]) > MAX_EXT_CALLED_PARTY_LENGTH) {
        // invalid or empty record
        return;
      }

      number += PhoneNumberUtils.calledPartyBCDFragmentToString(extRecord, 2, 0xff & extRecord[1]);

      // We don't support ext record chaining.

    } catch (RuntimeException ex) {
      Log.w(LOG_TAG, "Error parsing AdnRecord ext record", ex);
    }
  }
Esempio n. 2
0
  /** See TS 51.011 10.5.10 */
  public void appendExtRecord(byte[] extRecord) {
    try {
      if (extRecord.length != EXT_RECORD_LENGTH_BYTES) {
        return;
      }

      if ((extRecord[0] & EXT_RECORD_TYPE_MASK) != EXT_RECORD_TYPE_ADDITIONAL_DATA) {
        return;
      }

      if ((0xff & extRecord[1]) > MAX_EXT_CALLED_PARTY_LENGTH) {
        // invalid or empty record
        return;
      }

      number += PhoneNumberUtils.calledPartyBCDFragmentToString(extRecord, 2, 0xff & extRecord[1]);

      // We don't support ext record chaining.

    } catch (RuntimeException ex) {
      Log.w(LOG_TAG, "Error parsing AdnRecord ext record", ex);
    }
  }