Пример #1
0
unsigned long long PerformanceTiming::domainLookupEnd() const {
  ResourceLoadTiming* timing = resourceLoadTiming();
  if (!timing)
    return domainLookupStart();

  // This will be zero when a DNS request is not performed.  Rather than
  // exposing a special value that indicates no DNS, we "backfill" with
  // domainLookupStart.
  double dnsEnd = timing->dnsEnd();
  if (dnsEnd == 0.0)
    return domainLookupStart();

  return monotonicTimeToIntegerMilliseconds(dnsEnd);
}
unsigned long long PerformanceTiming::domainLookupEnd() const
{
    ResourceLoadTiming* timing = resourceLoadTiming();
    if (!timing)
        return domainLookupStart();

    // This will be -1 when a DNS request is not performed.
    // Rather than exposing a special value that indicates no DNS, we "backfill" with domainLookupStart.
    int dnsEnd = timing->dnsEnd;
    if (dnsEnd < 0)
        return domainLookupStart();

    return resourceLoadTimeRelativeToAbsolute(dnsEnd);
}
Пример #3
0
unsigned long long PerformanceTiming::domainLookupEnd() const
{
    DocumentLoader* loader = documentLoader();
    if (!loader)
        return domainLookupStart();
    
    const ResourceLoadTiming& timing = loader->response().resourceLoadTiming();
    
    // This will be -1 when a DNS request is not performed.
    // Rather than exposing a special value that indicates no DNS, we "backfill" with domainLookupStart.
    if (timing.domainLookupEnd < 0)
        return domainLookupStart();

    return resourceLoadTimeRelativeToAbsolute(timing.domainLookupEnd);
}
Пример #4
0
ScriptValue PerformanceTiming::toJSONForBinding(
    ScriptState* scriptState) const {
  V8ObjectBuilder result(scriptState);
  result.addNumber("navigationStart", navigationStart());
  result.addNumber("unloadEventStart", unloadEventStart());
  result.addNumber("unloadEventEnd", unloadEventEnd());
  result.addNumber("redirectStart", redirectStart());
  result.addNumber("redirectEnd", redirectEnd());
  result.addNumber("fetchStart", fetchStart());
  result.addNumber("domainLookupStart", domainLookupStart());
  result.addNumber("domainLookupEnd", domainLookupEnd());
  result.addNumber("connectStart", connectStart());
  result.addNumber("connectEnd", connectEnd());
  result.addNumber("secureConnectionStart", secureConnectionStart());
  result.addNumber("requestStart", requestStart());
  result.addNumber("responseStart", responseStart());
  result.addNumber("responseEnd", responseEnd());
  result.addNumber("domLoading", domLoading());
  result.addNumber("domInteractive", domInteractive());
  result.addNumber("domContentLoadedEventStart", domContentLoadedEventStart());
  result.addNumber("domContentLoadedEventEnd", domContentLoadedEventEnd());
  result.addNumber("domComplete", domComplete());
  result.addNumber("loadEventStart", loadEventStart());
  result.addNumber("loadEventEnd", loadEventEnd());
  return result.scriptValue();
}
double PerformanceResourceTiming::domainLookupEnd() const
{
    if (!m_allowTimingDetails)
        return 0.0;

    if (!m_timing || m_timing->dnsEnd() == 0.0)
        return domainLookupStart();

    return monotonicTimeToDOMHighResTimeStamp(m_timeOrigin, m_timing->dnsEnd());
}
double PerformanceResourceTiming::domainLookupEnd() const
{
    if (!m_shouldReportDetails)
        return 0.0;

    if (m_timing.domainLookupEnd < 0)
        return domainLookupStart();

    return resourceTimeToDocumentMilliseconds(m_timing.domainLookupEnd);
}
Пример #7
0
double PerformanceResourceTiming::domainLookupEnd() const
{
    if (!m_allowTimingDetails)
        return 0.0;

    if (!m_timing || m_timing->dnsEnd == 0.0)
        return domainLookupStart();

    return monotonicTimeToDocumentMilliseconds(m_requestingDocument.get(), m_timing->dnsEnd);
}
void PerformanceResourceTiming::buildJSONValue(V8ObjectBuilder& builder) const
{
    PerformanceEntry::buildJSONValue(builder);
    builder.addString("initiatorType", initiatorType());
    builder.addNumber("workerStart", workerStart());
    builder.addNumber("redirectStart", redirectStart());
    builder.addNumber("redirectEnd", redirectEnd());
    builder.addNumber("fetchStart", fetchStart());
    builder.addNumber("domainLookupStart", domainLookupStart());
    builder.addNumber("domainLookupEnd", domainLookupEnd());
    builder.addNumber("connectStart", connectStart());
    builder.addNumber("connectEnd", connectEnd());
    builder.addNumber("secureConnectionStart", secureConnectionStart());
    builder.addNumber("requestStart", requestStart());
    builder.addNumber("responseStart", responseStart());
    builder.addNumber("responseEnd", responseEnd());
}