public class

OpenInPlaceTranslated

extends OpenInPlace
java.lang.Object
   ↳ com.priint.comet.renderer.io.providers.builder.DocumentAccessProviderX
     ↳ com.priint.comet.renderer.io.providers.OpenInPlace
       ↳ com.priint.comet.renderer.io.providers.OpenInPlaceTranslated

Class Overview

DocumentAccessProvider implementation to open a document using the original path and translating the path to a representation resolvable for renderer processing the document referred by this DocumentAccessProvider.

We assume, that the document is accessible for the JVM running the rendering library and all renderer instances possibly processing the document referred by this DocumentAccessProvider, but the renderer requires another path representation (e.g. add prefix for drive, IP address...).

Summary

Nested Classes
class OpenInPlaceTranslated.PathTranslation  
Public Constructors
OpenInPlaceTranslated(Path path, String translateFrom, String translateTo)

Constructs a new OpenInPlaceTranslated provider.

OpenInPlaceTranslated(Path path, String[] translate)
Public Methods
void build()
String getDocumentUID()

Gets the path with replacements as specified with #translateFrom and #translateTo

[Expand]
Inherited Methods
From class com.priint.comet.renderer.io.providers.OpenInPlace
From class com.priint.comet.renderer.io.providers.builder.DocumentAccessProviderX
From class java.lang.Object
From interface com.priint.comet.renderer.io.DocumentAccessProvider

Public Constructors

public OpenInPlaceTranslated (Path path, String translateFrom, String translateTo)

Constructs a new OpenInPlaceTranslated provider.

Constructs a new OpenInPlaceTranslated provider.
The translateFrom part of the (local) representation of the document part is replaced by remorePrefix.
Example:
If the local path of the document is /usr/shared/documents/mydocument.indd, translateFrom is set to "/usr/shared/documents/" and translateTo is set to "\\192.168.17.6\documents\", the resolved path passed to the renderer is "\\192.168.17.6\documents\mydocument.indd"

Parameters
path path denoting the file to be opened
translateFrom this part at the beginning of the local path presentation is replaced by translateTo
translateTo String to be inserted at the beginning of the string truncated by translateFrom

public OpenInPlaceTranslated (Path path, String[] translate)

Public Methods

public void build ()

public String getDocumentUID ()

Gets the path with replacements as specified with #translateFrom and #translateTo

Returns
  • unique ID of the document