package key;
public class AccessViolationException
extends RuntimeException
implements UserOutputException
{
Object on;
public AccessViolationException( Object o, String msg )
{
super( msg );
on = o;
// determine who's fault it is
Player p = Player.getCurrent();
if( p != null )
Log.log( "security", p.getName() + ":" + msg + " (from: " + o.toString() + ":" + o.getClass().getName() + ")" );
else
Log.log( "security", "(system process):" + msg + " (from: " + o.toString() + ":" + o.getClass().getName() + ")" );
printStackTrace();
}
public void send( InteractiveConnection ic )
{
ic.sendFailure( "Access Violation while " + getMessage() );
}
}