de.scheisseichfindemalkeinen.settings.opera
Class OperaCookieInputStream

java.lang.Object
  extended by java.io.InputStream
      extended by java.io.FileInputStream
          extended by de.scheisseichfindemalkeinen.settings.opera.OperaCookieInputStream
All Implemented Interfaces:
java.io.Closeable

public class OperaCookieInputStream
extends java.io.FileInputStream

OperaCookieInputStream


Constructor Summary
OperaCookieInputStream(java.lang.String name)
           
 
Method Summary
static char byteToChar(byte[] arr, int start)
          Convert Bytes to Char
static int byteToInt(byte[] arr, int start)
          Convert Bytes to Int
static long byteToInt32(byte[] arr, int start)
          Convert UInt32 Bytes to Int32
static short byteToShort(byte[] arr, int start)
          Convert Bytes to Short
static int byteToUInt16(byte[] b)
          Convert Int16 Bytes to UInt16
static long byteToUInt24(byte[] b)
          Convert Int24 Bytes to UInt24
static long byteToUInt32(byte[] b)
          Convert Int32 Bytes to UInt32
static short byteToUInt8(byte[] b)
          Convert Int8 Bytes to UInt8
 int read()
           
 int read(byte[] b, int off, int len)
           
 int read(OperaCookie oc)
          Read Cookie
 int read(OperaCookieHeader och)
          Read header
 int read(OperaDomain od)
          Read Domain
 int read(OperaString str)
          Read String
 int readInt16(byte[] b)
          Read Bytes
 int readInt24(byte[] b)
          Read Bytes
 int readInt32(byte[] b)
          Read Bytes
 int readInt8(byte[] b)
          Read Bytes
 int readTimeT(byte[] b)
          Read time
 int readUInt16(byte[] b)
          Read Bytes
 int readUInt24(byte[] b)
          Read Bytes
 int readUInt32(byte[] b)
          Read Bytes
 int readUInt8(byte[] b)
          Read Bytes
 
Methods inherited from class java.io.FileInputStream
available, close, finalize, getChannel, getFD, read, skip
 
Methods inherited from class java.io.InputStream
mark, markSupported, reset
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OperaCookieInputStream

public OperaCookieInputStream(java.lang.String name)
                       throws java.io.FileNotFoundException
Parameters:
name -
Throws:
java.io.FileNotFoundException
Method Detail

readUInt8

public int readUInt8(byte[] b)
              throws java.io.IOException
Read Bytes

Parameters:
b - Buffer
Returns:
Bytes read
Throws:
java.io.IOException

readUInt16

public int readUInt16(byte[] b)
               throws java.io.IOException
Read Bytes

Parameters:
b - Buffer
Returns:
Bytes read
Throws:
java.io.IOException

readUInt24

public int readUInt24(byte[] b)
               throws java.io.IOException
Read Bytes

Parameters:
b - Buffer
Returns:
Bytes read
Throws:
java.io.IOException

readUInt32

public int readUInt32(byte[] b)
               throws java.io.IOException
Read Bytes

Parameters:
b - Buffer
Returns:
Bytes read
Throws:
java.io.IOException

readInt8

public int readInt8(byte[] b)
             throws java.io.IOException
Read Bytes

Parameters:
b - Buffer
Returns:
Bytes read
Throws:
java.io.IOException

readInt16

public int readInt16(byte[] b)
              throws java.io.IOException
Read Bytes

Parameters:
b - Buffer
Returns:
Bytes read
Throws:
java.io.IOException

readInt24

public int readInt24(byte[] b)
              throws java.io.IOException
Read Bytes

Parameters:
b - Buffer
Returns:
Bytes read
Throws:
java.io.IOException

readInt32

public int readInt32(byte[] b)
              throws java.io.IOException
Read Bytes

Parameters:
b - Buffer
Returns:
Bytes read
Throws:
java.io.IOException

byteToInt32

public static long byteToInt32(byte[] arr,
                               int start)
Convert UInt32 Bytes to Int32

Parameters:
arr - Bytes
start - Start
Returns:
Converted Bytes

byteToUInt32

public static long byteToUInt32(byte[] b)
Convert Int32 Bytes to UInt32

Parameters:
b - Bytes
Returns:
Converted Bytes

byteToUInt24

public static long byteToUInt24(byte[] b)
Convert Int24 Bytes to UInt24

Parameters:
b - Bytes
Returns:
Converted Bytes

byteToUInt16

public static int byteToUInt16(byte[] b)
Convert Int16 Bytes to UInt16

Parameters:
b - Bytes
Returns:
Converted Bytes

byteToUInt8

public static short byteToUInt8(byte[] b)
Convert Int8 Bytes to UInt8

Parameters:
b - Bytes
Returns:
Converted Bytes

byteToInt

public static int byteToInt(byte[] arr,
                            int start)
Convert Bytes to Int

Parameters:
arr - Bytes
start - Start
Returns:
Converted Bytes

byteToShort

public static short byteToShort(byte[] arr,
                                int start)
Convert Bytes to Short

Parameters:
arr - Bytes
start - Start
Returns:
Converted Bytes

byteToChar

public static char byteToChar(byte[] arr,
                              int start)
Convert Bytes to Char

Parameters:
arr - Bytes
start - Start
Returns:
Converted Bytes

readTimeT

public int readTimeT(byte[] b)
              throws java.io.IOException
Read time

Parameters:
b - Buffer
Returns:
Bytes read
Throws:
java.io.IOException

read

public int read(OperaString str)
         throws java.io.IOException
Read String

Parameters:
str - OperaString
Returns:
Bytes read
Throws:
java.io.IOException

read

public int read(OperaCookie oc)
         throws java.io.IOException
Read Cookie

Parameters:
oc - OperaCookie
Returns:
Bytes read
Throws:
java.io.IOException

read

public int read(OperaDomain od)
         throws java.io.IOException
Read Domain

Parameters:
od - OperaDomain
Returns:
Bytes read
Throws:
java.io.IOException

read

public int read(OperaCookieHeader och)
         throws java.io.IOException
Read header

Parameters:
och - OperaCookieHeader
Returns:
Bytes read
Throws:
java.io.IOException

read

public int read()
         throws java.io.IOException
Overrides:
read in class java.io.FileInputStream
Throws:
java.io.IOException

read

public int read(byte[] b,
                int off,
                int len)
         throws java.io.IOException
Overrides:
read in class java.io.FileInputStream
Throws:
java.io.IOException