public class Slug extends Object
| Constructor and Description |
|---|
Slug() |
| Modifier and Type | Method and Description |
|---|---|
static String |
slugify(String str)
Converts to lowercase, removes non-word characters (alphanumerics and
underscores) and converts spaces to hyphens.
|
static boolean |
validateSlug(String slug)
Checks to see if a slug is valid.
|
public static String slugify(String str)
str - The string to slugify.public static boolean validateSlug(String slug)
slug - the slug to check.Copyright © 2015 Collaborative Software Development Laboratory. All rights reserved.