Package com.exedio.cope.pattern
Class TextUrlFilter
java.lang.Object
com.exedio.cope.Feature
com.exedio.cope.Pattern
com.exedio.cope.pattern.MediaPath
com.exedio.cope.pattern.MediaFilter
com.exedio.cope.pattern.TextUrlFilter
- All Implemented Interfaces:
TextUrlFilterCheckable,Serializable
- See Also:
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class com.exedio.cope.pattern.MediaPath
MediaPath.Locator, MediaPath.Log, MediaPath.NotFound -
Constructor Summary
ConstructorsConstructorDescriptionTextUrlFilter(Media raw, String supportedContentType, String encoding, String pasteStart, String pasteStop, StringField pasteKey, Media pasteValue) Deprecated.TextUrlFilter(Media raw, String supportedContentType, Charset charset, String pasteStart, String pasteStop, StringField pasteKey, Media pasteValue) -
Method Summary
Modifier and TypeMethodDescriptionfinal TextUrlFilter.PasteaddPaste(Item item, String key, Media.Value value) protected voidappendKey(StringBuilder bf, Item item, String key, HttpServletRequest request) protected voidappendURL(StringBuilder bf, TextUrlFilter.Paste paste, HttpServletRequest request) final voiddoGetAndCommit(HttpServletRequest request, HttpServletResponse response, Item item) The implementor MUSTcommitthe transaction, if the method completes normally (without exception).final StringgetContent(Item item, HttpServletRequest request) final StringgetContentType(Item item) final MediaPath.LocatorgetPasteLocator(Item item, String key) final StringgetPasteUrl(Item item, String key) Deprecated.UsegetPasteURL(Item,String)insteadfinal StringgetPasteURL(Item item, String key) Deprecated.UsegetPasteContentTypesAllowed()insteadfinal booleanfinal voidmodifyPaste(Item item, String key, Media.Value value) protected final voidonMount()Here you can do additional initialization not yet done in the constructor.final TextUrlFilter.PasteputPaste(Item item, String key, Media.Value value) final voidputPastesFromZip(Item item, File file) final voidsetRaw(Item item, Media.Value raw) Methods inherited from class com.exedio.cope.pattern.MediaFilter
getLastModified, getLocatorWithFallbackToSource, getSource, getURLWithFallbackToSource, isFinal, isMandatory, isNotNull, isNotNull, isNull, isNullMethods inherited from class com.exedio.cope.pattern.MediaPath
commit, getExceptionLogs, getGuessedUrlLogs, getInfo, getInvalidSpecialLogs, getIsNullLogs, getLocator, getNamedURL, getNoSuchItemLogs, getNoSuchPath, getNoSuchPathLogs, getNotAnItemLogs, getNotComputableLogs, getURL, incrementDelivered, isUrlFingerPrinted, isUrlGuessingPrevented, isUrlGuessingPreventedSecurely, notFoundIsNull, notFoundNotComputableMethods inherited from class com.exedio.cope.Pattern
addSource, addSource, addSource, addSource, addSourceFeature, addSourceFeature, addSourceFeature, annotationField, equals, getGeneratedTypes, getSourceFeatures, getSourceFeaturesGather, getSourceFields, getSources, getSourceTypes, getType, hashCode, initialize, newSourceType, newSourceType, newSourceType, newSourceType, newSourceType, newSourceType, newType, newType, registerSourceMethods inherited from class com.exedio.cope.Feature
afterModelCreated, getAbstractType, getAnnotation, getID, getLocalizationKeys, getName, getPattern, isAnnotationPresent, isSourceAlready, mount, readResolve, requireMounted, toString, toString, writeReplace
-
Constructor Details
-
TextUrlFilter
-
TextUrlFilter
@Deprecated public TextUrlFilter(Media raw, String supportedContentType, String encoding, String pasteStart, String pasteStop, StringField pasteKey, Media pasteValue) Deprecated.
-
-
Method Details
-
setRaw
- Throws:
IOException
-
addPaste
@Nonnull public final TextUrlFilter.Paste addPaste(@Nonnull Item item, @Nonnull String key, @Nonnull Media.Value value) -
modifyPaste
public final void modifyPaste(@Nonnull Item item, @Nonnull String key, @Nonnull Media.Value value) throws IOException - Throws:
IOException
-
putPaste
@Nonnull public final TextUrlFilter.Paste putPaste(@Nonnull Item item, @Nonnull String key, @Nonnull Media.Value value) throws IOException - Throws:
IOException
-
getPasteLocator
-
getPasteURL
-
onMount
protected final void onMount()Description copied from class:PatternHere you can do additional initialization not yet done in the constructor. In this method you can call methodsPattern.getType()andFeature.getName()for the first time. -
getContentType
- Specified by:
getContentTypein classMediaPath
-
isContentTypeWrapped
public final boolean isContentTypeWrapped()- Overrides:
isContentTypeWrappedin classMediaPath
-
doGetAndCommit
public final void doGetAndCommit(HttpServletRequest request, HttpServletResponse response, Item item) throws IOException, MediaPath.NotFound Description copied from class:MediaPathThe implementor MUSTcommitthe transaction, if the method completes normally (without exception). Otherwise the implementor may or may not commit the transaction.- Specified by:
doGetAndCommitin classMediaPath- Throws:
IOExceptionMediaPath.NotFound
-
getContent
@Nonnull public final String getContent(@Nonnull Item item, @Nonnull HttpServletRequest request) throws MediaPath.NotFound - Throws:
MediaPath.NotFound
-
check
- Specified by:
checkin interfaceTextUrlFilterCheckable- Throws:
MediaPath.NotFound
-
appendKey
-
appendURL
-
getSupportedSourceContentTypes
- Specified by:
getSupportedSourceContentTypesin classMediaFilter
-
getPasteContentTypesAllowed
-
putPastesFromZip
- Throws:
IOException
-
getSupportedPasteContentTypes
Deprecated.UsegetPasteContentTypesAllowed()instead -
getPasteUrl
Deprecated.UsegetPasteURL(Item,String)instead
-
TextUrlFilter(Media, String, Charset, String, String, StringField, Media)instead