@JsonMapper.JsonMappingCompleted public void convertVersion() { version = Version.getVersionFromString(versionAsString); }
protected void fillHeaderAndDebugInfo(HttpURLConnection httpUrlConnection) { currentHeaders = Collections.unmodifiableMap(httpUrlConnection.getHeaderFields()); String usedApiVersion = StringUtils.trimToEmpty(httpUrlConnection.getHeaderField("facebook-api-version")); HTTP_LOGGER.debug("Facebook used the API {} to answer your request", usedApiVersion); String fbTraceId = StringUtils.trimToEmpty(httpUrlConnection.getHeaderField("x-fb-trace-id")); String fbRev = StringUtils.trimToEmpty(httpUrlConnection.getHeaderField("x-fb-rev")); String fbDebug = StringUtils.trimToEmpty(httpUrlConnection.getHeaderField("x-fb-debug")); String fbAppUsage = StringUtils.trimToEmpty(httpUrlConnection.getHeaderField("x-app-usage")); String fbPageUsage = StringUtils.trimToEmpty(httpUrlConnection.getHeaderField("x-page-usage")); Version usedVersion = Version.getVersionFromString(usedApiVersion); debugHeaderInfo = new DebugHeaderInfo(fbDebug, fbRev, fbTraceId, usedVersion, fbAppUsage, fbPageUsage); }