001
014
015 package com.liferay.portal.xml;
016
017 import com.liferay.portal.kernel.util.StringPool;
018 import com.liferay.portal.kernel.xml.DocumentType;
019
020
023 public class DocumentTypeImpl implements DocumentType {
024
025 public DocumentTypeImpl(org.dom4j.DocumentType documentType) {
026 _documentType = documentType;
027 }
028
029 public String getName() {
030 return _documentType.getName();
031 }
032
033 public String getPublicId() {
034 if (_documentType == null) {
035 return null;
036 }
037
038 return _documentType.getPublicID();
039 }
040
041 public String getSystemId() {
042 if (_documentType == null) {
043 return null;
044 }
045
046 return _documentType.getSystemID();
047 }
048
049 public org.dom4j.DocumentType getWrappedDocumentType() {
050 return _documentType;
051 }
052
053 @Override
054 public int hashCode() {
055 if (_documentType == null) {
056 return super.hashCode();
057 }
058
059 return _documentType.hashCode();
060 }
061
062 @Override
063 public String toString() {
064 if (_documentType == null) {
065 return StringPool.BLANK;
066 }
067
068 return _documentType.toString();
069 }
070
071 private org.dom4j.DocumentType _documentType;
072
073 }