|
Method DetailBuffer addData(Data data) Adds the Data to this Buffer for subsequent JEXL rendering (see toString() or toFile()).
Parameters:
Returns: Buffer Since: 11-01-2010 Buffer addDataList(DataList dataList) Adds the DataList to this Buffer for subsequent JEXL rendering (see render() or toFile()).
Parameters:
Returns: Buffer Since: 05-31-2011 Buffer addDataMap(String id, Data data) Adds the Data to this Buffer with the given id for subsequent JEXL rendering (see toString() or toFile()).
Parameters:
Returns: Buffer Since: 11-01-2010 Buffer addDataMaps(String keyColumn, DataList list) Extracts the records from the list and registers them in the Buffer using the values in the key column. Limited to 500 records.
Parameters:
Returns: Buffer Since: 11-01-2010 Buffer append(String string) Appends the given string to the buffer and returns the buffer
Parameters:
Returns: Buffer Since: 07-11-2008 Buffer append(int int) Appends the given int to the buffer and returns the buffer
Parameters:
Returns: Buffer Since: 07-11-2008 Buffer appendArray(String[] array, String delim) Appends the elements of array to this buffer, optionally separating them with delim.
Parameters:
Returns: Buffer Since: 06-07-2010 Buffer appendFile(File file) Appends the file content to this buffer and returns the buffer. If the file is not text, the contents are appended as base64.
Parameters:
Returns: Buffer Since: 08-24-2010 Buffer appendFragment(Fragment fragment) Appends the xhtml content of the fragment to this buffer and returns the buffer.
Parameters:
Returns: Buffer Since: 08-24-2010 clearMarkers() Clears the markers (start and end). Since: 09-12-2022 int endMarker(String find) Finds the first location of the matching string, starting from startMarker and returns the end location or -1 if not found. You must call startMarker before calling this method.
Parameters:
Returns: int Since: 02-05-2022 String getElement(String xpath) Returns the xhtml of the content identified by xpath.
Parameters:
Returns: String Since: 11-07-2017 String getMarker() Returns the content found between startMarker and endMarker, inclusive. Returns: String Since: 02-05-2022 Buffer lf() Appends a line feed to the buffer and returns the buffer. Returns: Buffer Since: 09-10-2010 Buffer quote() Appends a quote to the buffer and returns the buffer. Returns: Buffer Since: 09-10-2010 Buffer removeControlChars(boolean all) Removes all control characters in the range x0000 to x001F inclusive if all is true. If all is false, this will remove all control characters except tab, line feed, and carriage return.
Parameters:
Returns: Buffer Since: 11-24-2014 Buffer removeNonAsciiChars() Removes all characters outside of the UTF-8 C1 Controls and Latin1 Supplement (keeps characters in the range 0-255 decimal). Returns: Buffer Since: 03-05-2021 Buffer removeTags(String blockSeparator) Removes html tags from buffer content. Optionally can separate block elements with specified block separator string
Parameters:
Returns: Buffer Since: 05-31-2011 String render() Renders the content (requires well-formed XHTML), injecting dynamic content into the output. See Buffer.addDataList, Buffer.appendFragment, etc. Returns: String Since: 05-31-2011 Buffer replace(String find, String replace, boolean all) Finds occurrences of find and replaces it with replace. If all is true, all occurrences are replaced. Otherwise, the first occurrence is replaced.
Parameters:
Returns: Buffer Since: 07-11-2008 Buffer replaceElement(String xpath, String xhtml) Replaces the element identified with xpath with content defined by xhtml. If xhtml is null, it removes the element. Expects the underlying buffer content to be well-formed xhtml.
Parameters:
Returns: Buffer Since: 11-07-2017 replaceMarker(String replacement) Replaces the content found between startMarker and endMarker, inclusive.
Parameters:
Since: 02-05-2022 Buffer setValue(String key, String value) Adds the key/value pair to the Buffer, over-writing any set that already exists with name key.
Parameters:
Returns: Buffer Since: 11-01-2010 int startMarker(String find) Finds the first location of the matching string relative to the last marker and returns the location or -1 if not found. Resets the end mark.
Parameters:
Returns: int Since: 02-05-2022 File toBinaryFile(String fileName, String contentType) Returns the Base64 content of this Buffer as a File with the specified name and content type. Exception if the buffer content is not Base64 or does not match the contentType.
Parameters:
Returns: File Since: 05-16-2011 PacketDataList toDataList(String name) Creates a PacketDataList from the buffer contents (expected a serialized JSON DataList). See DataList.toJSON. If you pass null or empty for name, the datalist name will be what is already contained in the serialized JSON. Otherwise, the list will get the new name you provide.
Parameters:
Returns: PacketDataList Since: 08-30-2010 PacketDataList toDataList(String name, String columnName, String delim) Creates a one column PacketDataList from the buffer contents.
Parameters:
Returns: PacketDataList Since: 06-07-2010 PacketDataList toDataList(String name, String varName) Creates a PacketDataList from the buffer contents (expected a serialized JSON DataList). Targets the list identified by varName.
Parameters:
Returns: PacketDataList Since: 04-19-2012 Fragment toDocumentFragment(String name, boolean tidy) Creates a Fragment from the buffer content. The content must be well-formed xhtml and be comprised of legal content for a document fragment. Returns null if the content does not conform. If the content is not well-formed and tidy is true, we will attempt to clean it up. The content type should be html, txt, or xml.
Parameters:
Returns: Fragment Since: 08-24-2010 File toFile(String fileName) Returns the content of this Buffer as a File with the specified name. The fileName must have a text-based extension.
Parameters:
Returns: File Since: 11-01-2010 ImageFile toImage(String filename, int width, int height) Renders contents of this buffer as image
Parameters:
Returns: ImageFile Since: 06-08-2011 Fragment toPageFragment(String name, boolean tidy) Creates a Fragment from the buffer content. The content must be well-formed xhtml. If the content is not well-formed and tidy is true, we will attempt to clean it up. The content type should be html, txt, or xml. Returns null if the content cannot be parsed.
Parameters:
Returns: Fragment Since: 08-24-2010 String toString() Returns the content of the buffer as a string Returns: String Since: 07-11-2008 String toText() Returns content of this buffer as text (removes any XML/HTML tags). Returns: String Since: 09-28-2012 |
Copyright © 2006 - 2024, ContractPal, Inc. All rights reserved. | API Date: Nov 18, 2024 01:04 PM |