Package com.ironsoftware.ironpdf.render
Enum WaitForType
- java.lang.Object
-
- java.lang.Enum<WaitForType>
-
- com.ironsoftware.ironpdf.render.WaitForType
-
- All Implemented Interfaces:
Serializable
,Comparable<WaitForType>
public enum WaitForType extends Enum<WaitForType>
Type of wait-for for the user to have a chance to control when to commit rendering.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description AllFontsLoaded
This mode will begin rendering after all fonts have been loaded; be it local, remote, or google web fonts.HtmlElement
This mode will begin rendering when the specified HTML element becomes existent.ManualTrigger
This mode will wait until user calls internal IronPdf's JavaScript function `window.ironpdf.notifyRender()` that will trigger the rendering.NetworkIdle0
This mode will begin rendering when there is no new network request for 500ms as well as no inflight (outstanding) network requests.NetworkIdle2
This mode will begin rendering when there is no new network request for 500ms but allowed to have no more than 2 inflight (outstanding) network requests.NetworkIdleN
This mode will begin rendering when there is no new network request as per specified by user according to networkidle duration (in millisecond), and number of maximum allowed inflight (oustanding) network requests.None
Default type, no condition, no special need to do anything prior to rendering.RenderDelay
This mode will delay for specified amount of time before begin rendering.
-
Field Summary
Fields Modifier and Type Field Description static int
SIZE
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static WaitForType
forValue(int value)
int
getValue()
static WaitForType
valueOf(String name)
Returns the enum constant of this type with the specified name.static WaitForType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
None
public static final WaitForType None
Default type, no condition, no special need to do anything prior to rendering.
-
ManualTrigger
public static final WaitForType ManualTrigger
This mode will wait until user calls internal IronPdf's JavaScript function `window.ironpdf.notifyRender()` that will trigger the rendering.
-
RenderDelay
public static final WaitForType RenderDelay
This mode will delay for specified amount of time before begin rendering.
-
NetworkIdle0
public static final WaitForType NetworkIdle0
This mode will begin rendering when there is no new network request for 500ms as well as no inflight (outstanding) network requests. This mode is suitable for SPA (Single-Page Application) or web page that that doesn't have any on-going long polling network request.
-
NetworkIdle2
public static final WaitForType NetworkIdle2
This mode will begin rendering when there is no new network request for 500ms but allowed to have no more than 2 inflight (outstanding) network requests. This mode is suitable for web application or web page that has on-going long-polling or heartbeart ping request.
-
NetworkIdleN
public static final WaitForType NetworkIdleN
This mode will begin rendering when there is no new network request as per specified by user according to networkidle duration (in millisecond), and number of maximum allowed inflight (oustanding) network requests. This mode is suitable for customized type of web application or web page as per user's requirement that doesn't fit by usingNetworkIdle0
NetworkIdle2
-
HtmlElement
public static final WaitForType HtmlElement
This mode will begin rendering when the specified HTML element becomes existent.
-
AllFontsLoaded
public static final WaitForType AllFontsLoaded
This mode will begin rendering after all fonts have been loaded; be it local, remote, or google web fonts.
-
-
Field Detail
-
SIZE
public static final int SIZE
- See Also:
- Constant Field Values
-
-
Method Detail
-
values
public static WaitForType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (WaitForType c : WaitForType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static WaitForType valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
getValue
public int getValue()
-
forValue
public static WaitForType forValue(int value)
-
-