OrgLimit Class

Contains methods that provide the name, maximum value, and current value of an org limit.

System

Use the System.OrgLimits getAll and getMap methods to obtain either a list or a map of all your org limits. To get details on each limit, use instance methods from System.OrgLimit.

For comparison, the Limits Class returns Apex governor limits and not Salesforce API limits.

Limit values are updated asynchronously, in near-real-time.

The following are methods for OrgLimit.

  • getLimit()

    Returns the maximum allowed limit value.

  • getName()

    Returns the limit’s name.

  • getValue()

    Returns the limit usage value.

  • toString()

    Returns the string representation of the org limit.

Returns the maximum allowed limit value.

public Integer getLimit()

Type: Integer

Returns the limit’s name.

public String getName()

Type: String

Returns the limit usage value.

public Integer getValue()

Type: Integer

Returns the string representation of the org limit.

public String toString()

Type: String

String denoting the name, current consumption, and maximum value of the org limit. For example: