public class CondenserUtils extends Object
| Modifier and Type | Method and Description |
|---|---|
static String |
createPermlinkString(String title)
Create a permlink string from the given
title:
The title is trimmed and converted to lowercase
Spaces are converted to hyphens
Disallowed characters are removed
Contiguous hyphens are replaced with a single hyphen
|
static List<String> |
extractLinksFromContent(String content)
Get a list of links that the given
content contains. |
static List<String> |
extractUsersFromContent(String content)
Get a list of user names that the given
content contains. |
static String |
generateBeowulfitMetadata(String content,
String[] tags,
String app,
String format)
Use this method to generate the json metadata for new comments or posts
required by Condenser.
|
public static List<String> extractLinksFromContent(String content)
content contains.content - The content to extract the links from.public static List<String> extractUsersFromContent(String content)
content contains.content - The content to extract the user names from.public static String generateBeowulfitMetadata(String content, String[] tags, String app, String format)
content - The body of the comment or post.tags - The used tags for this comment or post.app - The app name that publishes this comment or post.format - The format used by the comment or post.public static String createPermlinkString(String title)
title:
title - The string to convertCopyright © 2019. All rights reserved.