Package nl.gx.webmanager.services.seo
Interface FriendlyURLEntity
-
- All Known Subinterfaces:
DBPageFriendlyURLEntity
,DumpedURLEntity
,MediaItemFriendlyURLEntity
,PageFriendlyURLEntity
public interface FriendlyURLEntity
Base interface representing one friendly URL.- Author:
- Sander Dahlberg
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
FriendlyURLEntity.ContentType
Represents the three types of friendly URL entities: page, mediaitem and database page.
-
Field Summary
Fields Modifier and Type Field Description static char
PATH_SEPARATOR
Deprecated.UseSEOUtil.getPathSeparator()
, or the slash character instead.
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description String
getAlternativePath()
Returns the alternative path of the entity.String
getBaseEntityIdentifier()
Returns the entity identifier without a potential sequence number.String
getBaseIdentifier()
Returns the URL identifier without a potential sequence number.String
getBaseURLTitleEntityIdentifier()
Returns the URL title entity without a potential sequence number.FriendlyURLEntity.ContentType
getContentType()
Returns the content type of the friendly URL entity.String
getEntityIdentifier()
Returns the entity identifier of the friendly URL.Date
getEntryDate()
Returns the creation or update date of the friendly URL.Integer
getId()
Returns the identifier of the friendly URL.String
getQueryString()
Returns the query string of the friendly URL.String
getQueryStringWithoutLangId()
Returns the query string of the friendly URL, but without the langid parameter.FriendlyURLEntity
getReference()
Returns the friendly URL entity referred to by the friendly URL.Integer
getSequenceNumber()
Returns the sequence number of the friendly URL.String
getURLIdentifier()
Returns the URL identifier of the friendly URL.String
getURLTitle()
Returns the URL title of the friendly URL.String
getURLTitleEntity()
Returns the last element of the URL title.Integer
getVersionId()
Returns the version id of the friendly URL.Integer
getWebsiteId()
Returns the website id of the friendly URL.boolean
isActivated()
Tells whether the friendly URL is activated.boolean
isAlternative()
Tells whether the friendly URL has an alternative path.boolean
isCanonical()
Determines if this friendly url is canonical.boolean
isCurrent()
Deprecated.UsegetReference() == null
instead.boolean
isLive()
Returns whether the content backed by the query string is last known to be current.
-
-
-
Field Detail
-
PATH_SEPARATOR
@Deprecated static final char PATH_SEPARATOR
Deprecated.UseSEOUtil.getPathSeparator()
, or the slash character instead.Path separator to separate the entity titles with.- See Also:
- Constant Field Values
-
-
Method Detail
-
getId
Integer getId()
Returns the identifier of the friendly URL.- Returns:
- The identifier of the friendly URL.
-
getURLIdentifier
String getURLIdentifier()
Returns the URL identifier of the friendly URL.- Returns:
- The URL identifier of the friendly URL.
-
getURLTitle
String getURLTitle()
Returns the URL title of the friendly URL.- Returns:
- The URL title of the friendly URL.
-
getEntityIdentifier
String getEntityIdentifier()
Returns the entity identifier of the friendly URL.- Returns:
- The entity identifier of the friendly URL.
-
getSequenceNumber
Integer getSequenceNumber()
Returns the sequence number of the friendly URL.- Returns:
- The sequence number of the friendly URL.
-
getVersionId
Integer getVersionId()
Returns the version id of the friendly URL.- Returns:
- The version id of the friendly URL.
-
getWebsiteId
Integer getWebsiteId()
Returns the website id of the friendly URL.- Returns:
- The website identifier of the friendly URL.
-
isLive
boolean isLive()
Returns whether the content backed by the query string is last known to be current.- Returns:
true
if the content backed by the query string is last known to be current,false
otherwise.
-
isActivated
boolean isActivated()
Tells whether the friendly URL is activated. A friendly URL is activated when the friendly URL is or has once been accessible by the outside world, and thus potentially indexed by search engines. If a friendly URL is updated while being activated the old friendly URL is remembered, so that it can be redirected to the new friendly URL if requested. If a friendly URL is updated while being not active the old friendly URL is simply overwritten.- Returns:
True
for a possible indexed friendly URL,false
otherwise.
-
isAlternative
boolean isAlternative()
Tells whether the friendly URL has an alternative path.- Returns:
True
for a friendly URL with an alternative path,false
otherwise.
-
getQueryString
String getQueryString()
Returns the query string of the friendly URL. This query string represents the internal resource backed by this friendly URL.- Returns:
- The query string of the friendly URL.
-
getQueryStringWithoutLangId
String getQueryStringWithoutLangId()
Returns the query string of the friendly URL, but without the langid parameter.- Returns:
- The query string of the friendly URL.
- Since:
- 10.35.0
-
getEntryDate
Date getEntryDate()
Returns the creation or update date of the friendly URL.- Returns:
- The creation or update date of the friendly URL.
-
getReference
FriendlyURLEntity getReference()
Returns the friendly URL entity referred to by the friendly URL. If notnull
the friendly URL is unavailable, and is redirected to the referred friendly URL.Note that only the id field of the referenced entity is set.
- Returns:
- The referenced friendly URL entity.
-
getContentType
FriendlyURLEntity.ContentType getContentType()
Returns the content type of the friendly URL entity.- Returns:
- The content type of the friendly URL entity.
-
getAlternativePath
String getAlternativePath()
Returns the alternative path of the entity. If the entity does not have an alternative path, an empty string is returned.- Returns:
- The alternative path of the friendly URL.
-
getBaseIdentifier
String getBaseIdentifier()
Returns the URL identifier without a potential sequence number. For example, if the URL identifier of a page isa/b/c 1
, where1
is the sequence number, then the result will bea/b/c
.- Returns:
- The URL identifier without the sequence number.
-
getBaseEntityIdentifier
String getBaseEntityIdentifier()
Returns the entity identifier without a potential sequence number. For example, if the entity identifier of a page isa 1
, where1
is the sequence number, then the result will bea
.- Returns:
- The entity identifier without the sequence number.
-
getBaseURLTitleEntityIdentifier
String getBaseURLTitleEntityIdentifier()
Returns the URL title entity without a potential sequence number. For example, if the URL title of a page isa/b/c 1
, where1
is the sequence number, then the result will bec
.- Returns:
- The URL title entity without the sequence number.
-
getURLTitleEntity
String getURLTitleEntity()
Returns the last element of the URL title. For example, if the URL title of a page isa/b/c
, the result will bec
.- Returns:
- The last element of the URL title.
-
isCurrent
@Deprecated boolean isCurrent()
Deprecated.UsegetReference() == null
instead.Tells whether the friendly URL is currently valid. The same asgetReference() == null
, as a friendly URL with a reference is one that redirects to a current one.- Returns:
True
when the friendly URL is currently valid,false
otherwise.
-
isCanonical
boolean isCanonical()
Determines if this friendly url is canonical. Only one url for any content item version can be canonical at the same time.- Returns:
-
-