Autopsy  4.11.0
Graphical digital forensics platform for The Sleuth Kit and other tools.
Public Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | Static Private Attributes | List of all members
org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator Class Reference

Inherits org.sleuthkit.autopsy.texttranslation.TextTranslator.

Public Member Functions

 GoogleTranslator ()
 
Component getComponent ()
 
int getMaxPayloadSize ()
 
String getName ()
 
void saveSettings ()
 
String translate (String string) throws TranslationException
 

Private Member Functions

void loadTranslator ()
 

Static Private Member Functions

static boolean googleIsReachable ()
 

Private Attributes

Translate googleTranslate
 
final GoogleTranslatorSettings settings = new GoogleTranslatorSettings()
 
final GoogleTranslatorSettingsPanel settingsPanel
 

Static Private Attributes

static final Logger logger = Logger.getLogger(GoogleTranslator.class.getName())
 
static final int MAX_PAYLOAD_SIZE = 5000
 

Detailed Description

TextTranslator which utilizes Google Cloud Translation to perform translation in Autopsy

Definition at line 47 of file GoogleTranslator.java.

Constructor & Destructor Documentation

org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.GoogleTranslator ( )

Constructs a new GoogleTranslator

Definition at line 59 of file GoogleTranslator.java.

Member Function Documentation

Component org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.getComponent ( )

Get the component to display on the settings options panel when this TextTranslator is selected

Returns
the component which displays the settings options

Implements org.sleuthkit.autopsy.texttranslation.TextTranslator.

Definition at line 136 of file GoogleTranslator.java.

int org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.getMaxPayloadSize ( )

Returns the hard limit for translation request sizes.

Returns

Implements org.sleuthkit.autopsy.texttranslation.TextTranslator.

Definition at line 183 of file GoogleTranslator.java.

String org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.getName ( )

Get the name of the TextTranslator implementation

Returns
the name of the TextTranslator

Implements org.sleuthkit.autopsy.texttranslation.TextTranslator.

Definition at line 131 of file GoogleTranslator.java.

static boolean org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.googleIsReachable ( )
staticprivate

Check if google is able to be reached

Returns
true if it can be, false otherwise

Definition at line 70 of file GoogleTranslator.java.

void org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.loadTranslator ( )
private

Load the Google Cloud Translation service given the currently saved settings

Definition at line 144 of file GoogleTranslator.java.

void org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.saveSettings ( )

Save the settings as they have been modified in the component.

Implements org.sleuthkit.autopsy.texttranslation.TextTranslator.

Definition at line 175 of file GoogleTranslator.java.

String org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.translate ( String  input) throws TranslationException

Translates a provided string

Parameters
inputthe String to translate
Returns
the translated String
Exceptions
TranslationException

Implements org.sleuthkit.autopsy.texttranslation.TextTranslator.

Definition at line 86 of file GoogleTranslator.java.

References org.sleuthkit.autopsy.coreutils.EscapeUtil.unEscapeHtml().

Member Data Documentation

Translate org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.googleTranslate
private

Definition at line 54 of file GoogleTranslator.java.

final Logger org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.logger = Logger.getLogger(GoogleTranslator.class.getName())
staticprivate

Definition at line 49 of file GoogleTranslator.java.

final int org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.MAX_PAYLOAD_SIZE = 5000
staticprivate

Definition at line 51 of file GoogleTranslator.java.

final GoogleTranslatorSettings org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.settings = new GoogleTranslatorSettings()
private

Definition at line 53 of file GoogleTranslator.java.

final GoogleTranslatorSettingsPanel org.sleuthkit.autopsy.texttranslation.translators.GoogleTranslator.settingsPanel
private

Definition at line 52 of file GoogleTranslator.java.


The documentation for this class was generated from the following file:

Copyright © 2012-2018 Basis Technology. Generated on: Fri Jun 21 2019
This work is licensed under a Creative Commons Attribution-Share Alike 3.0 United States License.