Class Frame


  • public class Frame
    extends java.lang.Object
    Information about the Frame on the page.
    • Constructor Detail

      • Frame

        public Frame​(FrameId id,
                     java.util.Optional<FrameId> parentId,
                     LoaderId loaderId,
                     java.util.Optional<java.lang.String> name,
                     java.lang.String url,
                     java.util.Optional<java.lang.String> urlFragment,
                     java.lang.String domainAndRegistry,
                     java.lang.String securityOrigin,
                     java.lang.String mimeType,
                     java.util.Optional<java.lang.String> unreachableUrl,
                     java.util.Optional<AdFrameStatus> adFrameStatus,
                     SecureContextType secureContextType,
                     CrossOriginIsolatedContextType crossOriginIsolatedContextType,
                     java.util.List<GatedAPIFeatures> gatedAPIFeatures)
    • Method Detail

      • getId

        public FrameId getId()
        Frame unique identifier.
      • getParentId

        public java.util.Optional<FrameId> getParentId()
        Parent frame identifier.
      • getLoaderId

        public LoaderId getLoaderId()
        Identifier of the loader associated with this frame.
      • getName

        public java.util.Optional<java.lang.String> getName()
        Frame's name as specified in the tag.
      • getUrl

        public java.lang.String getUrl()
        Frame document's URL without fragment.
      • getUrlFragment

        @Beta
        public java.util.Optional<java.lang.String> getUrlFragment()
        Frame document's URL fragment including the '#'.
      • getDomainAndRegistry

        @Beta
        public java.lang.String getDomainAndRegistry()
        Frame document's registered domain, taking the public suffixes list into account. Extracted from the Frame's url. Example URLs: http://www.google.com/file.html -> "google.com" http://a.b.co.uk/file.html -> "b.co.uk"
      • getSecurityOrigin

        public java.lang.String getSecurityOrigin()
        Frame document's security origin.
      • getMimeType

        public java.lang.String getMimeType()
        Frame document's mimeType as determined by the browser.
      • getUnreachableUrl

        @Beta
        public java.util.Optional<java.lang.String> getUnreachableUrl()
        If the frame failed to load, this contains the URL that could not be loaded. Note that unlike url above, this URL may contain a fragment.
      • getAdFrameStatus

        @Beta
        public java.util.Optional<AdFrameStatus> getAdFrameStatus()
        Indicates whether this frame was tagged as an ad and why.
      • getSecureContextType

        @Beta
        public SecureContextType getSecureContextType()
        Indicates whether the main document is a secure context and explains why that is the case.
      • getCrossOriginIsolatedContextType

        @Beta
        public CrossOriginIsolatedContextType getCrossOriginIsolatedContextType()
        Indicates whether this is a cross origin isolated context.
      • getGatedAPIFeatures

        @Beta
        public java.util.List<GatedAPIFeatures> getGatedAPIFeatures()
        Indicated which gated APIs / features are available.