Copyright© 2008-2022 Sitevision AB, all rights reserved.
public enum DocType extends Enum<DocType>
Example of how to get the HTML5
type:
#set ($instanceCreatorUtil = $sitevisionUtils.instanceCreatorUtil)
#set ($enumClassName = 'senselogic.sitevision.api.webresource.doctype.DocType')
#set ($html5Enum = $instanceCreatorUtil.getEnumInstance($enumClassName, 'HTML5'))
var html5Enum = require('DocType.HTML5');
Enum Constant and Description |
---|
HTML4_TRANSITIONAL
The HTML 4.01 Transitional doctype
|
HTML5
The HTML5 doctype
|
NO_DOCTYPE
The "null" value of this enum, for cases where a doctype isn't really applicable
|
XHTML1_STRICT
The XHTML 1.0 Strict doctype
|
XHTML1_TRANSITIONAL
The XHTML 1.0 Transitional doctype
|
Modifier and Type | Method and Description |
---|---|
String |
getDocTypeName()
The short and easy-to-understand name of the doctype.
|
String |
getDocTypeString()
The doctype definition string (as seen as first line in valid html/xhtml documents).
|
static DocType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static DocType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
@Requireable(value="DocType.NO_DOCTYPE") public static final DocType NO_DOCTYPE
@Requireable(value="DocType.HTML4_TRANSITIONAL") public static final DocType HTML4_TRANSITIONAL
@Requireable(value="DocType.XHTML1_TRANSITIONAL") public static final DocType XHTML1_TRANSITIONAL
@Requireable(value="DocType.XHTML1_STRICT") public static final DocType XHTML1_STRICT
@Requireable(value="DocType.HTML5") public static final DocType HTML5
public static DocType[] values()
for (DocType c : DocType.values()) System.out.println(c);
public static DocType valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic String getDocTypeString()
An example: the doctype string for XHTML1_STRICT
is
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
public String getDocTypeName()
An example: the doctype name for XHTML1_STRICT
is XHTML 1.0 Strict
Sitevision - Portal and Content Management Made Easy
Sitevision is an advanced Java enterprise portal product and a portlet container (JSR 286) that implements Java Content Repository (JSR 283).
Copyright© 2008-2022 Sitevision AB, all rights reserved.