com.wjholden.nmap
Class NmapError

java.lang.Object
  extended by com.wjholden.nmap.NmapError
All Implemented Interfaces:
NmapConstants

public final class NmapError
extends java.lang.Object
implements NmapConstants

NmapError is an error logging utility designed to save information that previously went to Log.d. Many users do not know hot to get debugging information from Logcat.
Before 0.4.8 there was an instance of NmapError that statically referenced by everything else and it was messy and confusing. Now, this class is a singleton (with a private constructor) that everybody can access easily and should be great.

Since:
0.4.1
Version:
0.2
Author:
William John Holden (wjholden@gmail.com)

Field Summary
private static java.util.List<java.lang.String> ERROR_LOG
           
private static NmapError FINAL_INSTANCE
           
 
Fields inherited from interface com.wjholden.nmap.NmapConstants
BUFFER_SIZE, FORCE_RESTART, INSTALL_ERROR, INSTALL_FILENAMES, INSTALL_GOOD, INSTALL_NO_ROOT, INSTALL_RESOURCES, MG_DEBUG, MG_DEFAULT, MG_SUBNET, MI_BIN, MI_DEBUG_EMAIL, MI_DEBUG_ENABLE, MI_DEC, MI_EMAIL_SUBNET, MI_EXIT, MI_HEX, MI_MORE_HELP, MI_REINSTALL, MI_SUBNET, MI_SURVEY, RUN_COMPLETE, RUN_ERROR, RUN_SUCCESS_NO_FILE, SCANTYPE_NCAT, SCANTYPE_NDIFF, SCANTYPE_NMAP_5_30, SCANTYPE_NMAP_5_50, SCANTYPE_NPING, SET_TITLE, SUBNET_CONNECTED, SUBNET_DISCONNECTED, SUBNET_POLL_INTERVAL, TAG, THREAD_ERROR
 
Constructor Summary
private NmapError()
           
 
Method Summary
static java.lang.String getLog()
          Grabs all lines of output previously stored using NmapError.Log(String).
static void log(java.lang.String string)
          Commit a new entry into the log.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ERROR_LOG

private static final java.util.List<java.lang.String> ERROR_LOG

FINAL_INSTANCE

private static final NmapError FINAL_INSTANCE
Constructor Detail

NmapError

private NmapError()
Method Detail

getLog

public static java.lang.String getLog()
Grabs all lines of output previously stored using NmapError.Log(String).

Returns:
All lines of output, separated by newlines.

log

public static void log(java.lang.String string)
Commit a new entry into the log. If Nmap.DEBUG is true then the entry will also output to Logcat.

Parameters:
string - The String Logged.