PageNumber
Inheritance: java.lang.Object, com.aspose.pdf.artifacts.pagination.PageNumber
public final class PageNumber extends Object
Represents a page number format that includes an index, total number of pages, and a delimiter.
Constructors
| Constructor | Description |
|---|---|
| PageNumber |
Methods
| Method | Description |
|---|---|
| getDelimiter | Gets or sets the delimiter used in the page number format. The formatted string will be updated based on the specified delimiter. |
| getIndex | Gets or sets the page index component of the page number format. The formatted string will include a placeholder for the page index. |
| getOffset | Gets or sets the offset to be added to the page index. |
| getPageNumberString | Returns a formatted string representing the page number based on the current settings. |
| getTotalNum | Gets or sets the total number of pages component of the page number format. The formatted string will include a placeholder for the total number of pages. |
| setDelimiter | Gets or sets the delimiter used in the page number format. The formatted string will be updated based on the specified delimiter. |
| setIndex | Gets or sets the page index component of the page number format. |
| setOffset | Gets or sets the offset to be added to the page index. |
| setTotalNum | Gets or sets the total number of pages component of the page number format. |
PageNumber
public PageNumber()
getDelimiter
public final String getDelimiter()
Gets or sets the delimiter used in the page number format. The formatted string will be updated based on the specified delimiter.
Returns: String value
getIndex
public final PageNumber.PageIndex getIndex()
Gets or sets the page index component of the page number format. The formatted string will include a placeholder for the page index.
Returns: PageIndex instance
getOffset
public final int getOffset()
Gets or sets the offset to be added to the page index.
Returns: int value
getPageNumberString
public final String getPageNumberString(int pageNumber, int count)
Returns a formatted string representing the page number based on the current settings.
Parameters:
| Parameter | Type | Description |
|---|---|---|
| pageNumber | The current page number. | |
| count | The total number of pages. |
Returns: A formatted page number string.
getTotalNum
public final PageNumber.PageTotalNum getTotalNum()
Gets or sets the total number of pages component of the page number format. The formatted string will include a placeholder for the total number of pages.
Returns: PageTotalNum instance
setDelimiter
Gets or sets the delimiter used in the page number format. The formatted string will be updated based on the specified delimiter.
setIndex
Gets or sets the page index component of the page number format.
setOffset
public final void setOffset(int value)
Gets or sets the offset to be added to the page index.
Parameters:
| Parameter | Type | Description |
|---|---|---|
| value | int value |
setTotalNum
Gets or sets the total number of pages component of the page number format.