@Test public void testCidWithoutDash() throws ValidationException { AdWordsSession session = getTestAdWordsSessionWithoutCid(); session.setClientCustomerId(CID_WITHOUT_DASH); assertEquals( "Valid cid without dash test failed.", CID_VALID, AdWordsSessionUtil.getClientCustomerId(session)); }
public static long getClientCustomerId(AdWordsSession session) { String accountIdStr = session.getClientCustomerId(); if (accountIdStr == null) { return VIRTUAL_CID; } try { return Long.parseLong(accountIdStr.replace("-", "")); } catch (NumberFormatException e) { throw new RateLimiterException("Encountered invalid CID: " + accountIdStr, e); } }
AdWordsSessionUtil { public static long getClientCustomerId(AdWordsSession session) { String accountIdStr = session.getClientCustomerId(); if (accountIdStr == null) { return VIRTUAL_CID; } try { return Long.parseLong(accountIdStr.replace("-", "")); } catch (NumberFormatException e) { throw new RateLimiterException("Encountered invalid CID: " + accountIdStr, e); } } }
AdWordsSessionUtil { public static long getClientCustomerId(AdWordsSession session) { String accountIdStr = session.getClientCustomerId(); if (accountIdStr == null) { return VIRTUAL_CID; } try { return Long.parseLong(accountIdStr.replace("-", "")); } catch (NumberFormatException e) { throw new RateLimiterException("Encountered invalid CID: " + accountIdStr, e); } }  }
AdWordsSessionUtil { public static long getClientCustomerId(AdWordsSession session) { String accountIdStr = session.getClientCustomerId(); if (accountIdStr == null) { return VIRTUAL_CID; } try { return Long.parseLong(accountIdStr.replace("-", "")); } catch (NumberFormatException e) { throw new RateLimiterException("Encountered invalid CID: " + accountIdStr, e); } }  static long getClientCustomerId(AdWordsSession session); }
AdWordsSessionUtil { public static long getClientCustomerId(AdWordsSession session) { String accountIdStr = session.getClientCustomerId(); if (accountIdStr == null) { return VIRTUAL_CID; } try { return Long.parseLong(accountIdStr.replace("-", "")); } catch (NumberFormatException e) { throw new RateLimiterException("Encountered invalid CID: " + accountIdStr, e); } }  static long getClientCustomerId(AdWordsSession session); static final long VIRTUAL_CID; }