| Method from org.apache.catalina.connector.CoyoteInputStream Detail: |
public int available() throws IOException {
if (SecurityUtil.isPackageProtectionEnabled()){
try{
Integer result =
(Integer)AccessController.doPrivileged(
new PrivilegedExceptionAction(){
public Object run() throws IOException{
Integer integer = new Integer(ib.available());
return integer;
}
});
return result.intValue();
} catch(PrivilegedActionException pae){
Exception e = pae.getException();
if (e instanceof IOException){
throw (IOException)e;
} else {
throw new RuntimeException(e.getMessage());
}
}
} else {
return ib.available();
}
}
|
void clear() {
ib = null;
}
|
protected Object clone() throws CloneNotSupportedException {
throw new CloneNotSupportedException();
}
Prevent cloning the facade. |
public void close() throws IOException {
if (SecurityUtil.isPackageProtectionEnabled()){
try{
AccessController.doPrivileged(
new PrivilegedExceptionAction(){
public Object run() throws IOException{
ib.close();
return null;
}
});
} catch(PrivilegedActionException pae){
Exception e = pae.getException();
if (e instanceof IOException){
throw (IOException)e;
} else {
throw new RuntimeException(e.getMessage());
}
}
} else {
ib.close();
}
}
Close the stream
Since we re-cycle, we can't allow the call to super.close()
which would permantely disable us. |
public int read() throws IOException {
if (SecurityUtil.isPackageProtectionEnabled()){
try{
Integer result =
(Integer)AccessController.doPrivileged(
new PrivilegedExceptionAction(){
public Object run() throws IOException{
Integer integer = new Integer(ib.readByte());
return integer;
}
});
return result.intValue();
} catch(PrivilegedActionException pae){
Exception e = pae.getException();
if (e instanceof IOException){
throw (IOException)e;
} else {
throw new RuntimeException(e.getMessage());
}
}
} else {
return ib.readByte();
}
}
|
public int read(byte[] b) throws IOException {
if (SecurityUtil.isPackageProtectionEnabled()){
try{
Integer result =
(Integer)AccessController.doPrivileged(
new PrivilegedExceptionAction(){
public Object run() throws IOException{
Integer integer =
new Integer(ib.read(b, 0, b.length));
return integer;
}
});
return result.intValue();
} catch(PrivilegedActionException pae){
Exception e = pae.getException();
if (e instanceof IOException){
throw (IOException)e;
} else {
throw new RuntimeException(e.getMessage());
}
}
} else {
return ib.read(b, 0, b.length);
}
}
|
public int read(byte[] b,
int off,
int len) throws IOException {
if (SecurityUtil.isPackageProtectionEnabled()){
try{
Integer result =
(Integer)AccessController.doPrivileged(
new PrivilegedExceptionAction(){
public Object run() throws IOException{
Integer integer =
new Integer(ib.read(b, off, len));
return integer;
}
});
return result.intValue();
} catch(PrivilegedActionException pae){
Exception e = pae.getException();
if (e instanceof IOException){
throw (IOException)e;
} else {
throw new RuntimeException(e.getMessage());
}
}
} else {
return ib.read(b, off, len);
}
}
|
public int readLine(byte[] b,
int off,
int len) throws IOException {
return super.readLine(b, off, len);
}
|