bugged stringlengths 6 599k | fixed stringlengths 10 599k | __index_level_0__ int64 0 1.13M |
|---|---|---|
public CipherInputStream(InputStream in, Cipher cipher) { this(in); this.cipher = cipher; if (!(isStream = cipher.getBlockSize() == 1)) { inBuffer = new byte[2][]; inBuffer[0] = new byte[cipher.getBlockSize()]; inBuffer[1] = new byte[cipher.getBlockSize()]; inLength = 0; ... | public CipherInputStream(InputStream in, Cipher cipher) { super (in); this.cipher = cipher; if (!(isStream = cipher.getBlockSize() == 1)) { inBuffer = new byte[2][]; inBuffer[0] = new byte[cipher.getBlockSize()]; inBuffer[1] = new byte[cipher.getBlockSize()]; inLength = 0; ... | 13,504 |
public CipherInputStream(InputStream in, Cipher cipher) { this(in); this.cipher = cipher; if (!(isStream = cipher.getBlockSize() == 1)) { inBuffer = new byte[2][]; inBuffer[0] = new byte[cipher.getBlockSize()]; inBuffer[1] = new byte[cipher.getBlockSize()]; inLength = 0; ... | public CipherInputStream(InputStream in, Cipher cipher) { this(in); this.cipher = cipher; if (!(isStream = cipher.getBlockSize() == 1)) { inBuffer = new byte[2][]; inBuffer[0] = new byte[cipher.getBlockSize()]; inBuffer[1] = new byte[cipher.getBlockSize()]; inLength = 0; ... | 13,505 |
public int available() throws IOException { if (isStream) return super.available(); return outLength - outOffset; } | public int available() throws IOException { if (isStream) return super.available(); if (outBuffer == null || outOffset >= outBuffer.length) nextBlock (); return outBuffer.length - outOffset; } | 13,506 |
public void close() throws IOException { super.close(); } | public synchronized void close() throws IOException { super.close(); } | 13,507 |
private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | 13,508 |
private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | 13,509 |
private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { outBuffer = null; outOffset = 0; while (outBuffer == null) { int... | 13,510 |
private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | 13,511 |
private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | 13,512 |
private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | 13,513 |
private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | 13,514 |
private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | 13,515 |
private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | private void nextBlock() throws IOException { byte[] temp = inBuffer[0]; inBuffer[0] = inBuffer[1]; inBuffer[1] = temp; int count = 0; boolean eof = false; if (state == VIRGIN || state == LIVING) { do { int l = in.read(inBuffer[1], count, inBuffer[1].length - count);... | 13,516 |
public int read() throws IOException { if (isStream) { byte[] buf = new byte[1]; int in = super.read(); if (in == -1) return -1; buf[0] = (byte) in; try { cipher.update(buf, 0, 1, buf, 0); } catch (ShortBufferException shouldNotH... | public synchronized int read() throws IOException { if (isStream) { byte[] buf = new byte[1]; int in = super.read(); if (in == -1) return -1; buf[0] = (byte) in; try { cipher.update(buf, 0, 1, buf, 0); } catch (ShortBufferExcepti... | 13,517 |
public int read() throws IOException { if (isStream) { byte[] buf = new byte[1]; int in = super.read(); if (in == -1) return -1; buf[0] = (byte) in; try { cipher.update(buf, 0, 1, buf, 0); } catch (ShortBufferException shouldNotH... | public int read() throws IOException { if (isStream) { byte[] buf = new byte[1]; int in = super.read(); if (in == -1) return -1; buf[0] = (byte) in; try { cipher.update(buf, 0, 1, buf, 0); } catch (ShortBufferException shouldNotH... | 13,518 |
public long skip(long bytes) throws IOException { if (isStream) { return super.skip(bytes); } long ret = 0; if (bytes > 0 && available() > 0) { ret = available(); outOffset = outLength = 0; } return ret; } | public long skip(long bytes) throws IOException { if (isStream) { return super.skip(bytes); } long ret = 0; if (bytes > 0 && outBuffer != null && outOffset >= outBuffer.length) { ret = available(); outOffset = outLength = 0; } return ret; } | 13,519 |
public long skip(long bytes) throws IOException { if (isStream) { return super.skip(bytes); } long ret = 0; if (bytes > 0 && available() > 0) { ret = available(); outOffset = outLength = 0; } return ret; } | public long skip(long bytes) throws IOException { if (isStream) { return super.skip(bytes); } long ret = 0; if (bytes > 0 && available() > 0) { ret = available(); outOffset = outLength = 0; } return ret; } | 13,520 |
public Object evaluate(Node context, int pos, int len) { Object val = (arg == null) ? null : arg.evaluate(context, pos, len); return _local_name(context, (Collection) val); } | public Object evaluate(Node context, int pos, int len) { Object val = (arg == null) ? Collections.singleton(context) : arg.evaluate(context, pos, len); return _local_name(context, (Collection) val); } | 13,521 |
public synchronized void fireEvent(KeyboardEvent event) { if (event != null) { for (Iterator i = listeners.iterator(); i.hasNext();) { KeyboardListener l = (KeyboardListener) i.next(); if (event.isKeyPressed()) { l.keyPressed(event); } else if (event.isKeyReleased()) { l.keyReleased(event); } ... | public synchronized void fireEvent(KeyboardEvent event) { if (event != null) { for (Iterator i = listeners.iterator(); i.hasNext();) { KeyboardListener l = (KeyboardListener) i.next(); if (event.isKeyPressed()) { l.keyPressed(event); } else if (event.isKeyReleased()) { l.keyReleased(event); } ... | 13,523 |
public String readLine() throws IOException { if (eof) { return null; } do { if (blockReads) { // Use mark and reset to read chunks of bytes final int MIN_LENGTH = 1024; int len, pos; len = in.available(); ... | public String readLine() throws IOException { if (eof) { return null; } do { if (blockReads) { // Use mark and reset to read chunks of bytes final int MAX_LENGTH = 1024; int len, pos; len = in.available(); ... | 13,525 |
public String readLine() throws IOException { if (eof) { return null; } do { if (blockReads) { // Use mark and reset to read chunks of bytes final int MIN_LENGTH = 1024; int len, pos; len = in.available(); ... | public String readLine() throws IOException { if (eof) { return null; } do { if (blockReads) { // Use mark and reset to read chunks of bytes final int MIN_LENGTH = 1024; int len, pos; len = in.available(); ... | 13,526 |
public static String[] read(InputStream input) { StringSeqHolder h = new StringSeqHolder(); h._read(input); return h.value; } | public static String[] read(InputStream input) { StringSeqHolder h = new StringSeqHolder(); h._read(input); return h.value; } | 13,527 |
public static void write(OutputStream output, String[] value) { StringSeqHolder h = new StringSeqHolder(value); h._write(output); } | public static void write(OutputStream output, String[] value) { StringSeqHolder h = new StringSeqHolder(value); h._write(output); } | 13,528 |
public Object clone() { try { return super.clone(); } catch (Exception e) { System.err.println("Huuuhhh, this class implements cloneable !!!!!!"); System.err.println("I think there is a bug in this JVM somewhere"); } return null; } | public Object clone() { try { return super.clone(); } catch (Exception e) { System.err.println("Huuuhhh, this class implements cloneable !!!!!!"); System.err.println("I think there is a bug in this JVM somewhere"); } return null; } | 13,529 |
public Ext2FileSystem(Device device, boolean readOnly) throws FileSystemException { super(device, readOnly); log.setLevel(Level.INFO); blockCache = new BlockCache(50,(float)0.75); inodeCache = new INodeCache(50,(float)0.75); //groupDescriptorLock = new Object(); //superblockLock = new Object(); } | public Ext2FileSystem(Device device, boolean readOnly) throws FileSystemException { super(device, readOnly); log.setLevel(Level.INFO); blockCache = new BlockCache(50,(float)0.75); inodeCache = new INodeCache(50,(float)0.75); //groupDescriptorLock = new Object(); //superblockLock = new Object(); } | 13,531 |
public Ext2FileSystem(Device device, boolean readOnly) throws FileSystemException { super(device, readOnly); log.setLevel(Level.INFO); blockCache = new BlockCache(50,(float)0.75); inodeCache = new INodeCache(50,(float)0.75); //groupDescriptorLock = new Object(); //superblockLock = new Object(); } | public Ext2FileSystem(Device device, boolean readOnly) throws FileSystemException { super(device, readOnly); log.setLevel(Level.INFO); blockCache = new BlockCache(50,(float)0.75); inodeCache = new INodeCache(50,(float)0.75); //groupDescriptorLock = new Object(); //superblockLock = new Object(); blockCache = n... | 13,532 |
protected FSEntry buildRootEntry() throws IOException { //a free inode has been found: create the inode and write it into the inode table INodeTable iNodeTable = iNodeTables[0]; //byte[] iNodeData = new byte[INode.INODE_LENGTH]; int iNodeNr = Ext2Constants.EXT2_ROOT_INO; INode iNode = new INode(this, new INode... | protected FSEntry buildRootEntry() throws IOException { //a free inode has been found: create the inode and write it into the inode table INodeTable iNodeTable = iNodeTables[0]; //byte[] iNodeData = new byte[INode.INODE_LENGTH]; int iNodeNr = Ext2Constants.EXT2_ROOT_INO; INode iNode = new INode(this, new INode... | 13,533 |
protected FSEntry buildRootEntry() throws IOException { //a free inode has been found: create the inode and write it into the inode table INodeTable iNodeTable = iNodeTables[0]; //byte[] iNodeData = new byte[INode.INODE_LENGTH]; int iNodeNr = Ext2Constants.EXT2_ROOT_INO; INode iNode = new INode(this, new INode... | protected FSEntry buildRootEntry() throws IOException { //a free inode has been found: create the inode and write it into the inode table INodeTable iNodeTable = iNodeTables[0]; //byte[] iNodeData = new byte[INode.INODE_LENGTH]; int iNodeNr = Ext2Constants.EXT2_ROOT_INO; INode iNode = new INode(this, new INode... | 13,534 |
public void create(int blockSize) throws FileSystemException { try{ //create the superblock superblock = new Superblock(); superblock.create(blockSize, this); //create the group descriptors groupCount = (int)Math.ceil((double)superblock.getBlocksCount() / (double)superblock.getBlocksPerGroup()); groupD... | public void create(int blockSize) throws FileSystemException { try{ //create the superblock superblock = new Superblock(); superblock.create(blockSize, this); //create the group descriptors groupCount = (int)Math.ceil((double)superblock.getBlocksCount() / (double)superblock.getBlocksPerGroup()); groupD... | 13,535 |
public void create(int blockSize) throws FileSystemException { try{ //create the superblock superblock = new Superblock(); superblock.create(blockSize, this); //create the group descriptors groupCount = (int)Math.ceil((double)superblock.getBlocksCount() / (double)superblock.getBlocksPerGroup()); groupD... | public void create(int blockSize) throws FileSystemException { try{ //create the superblock superblock = new Superblock(); superblock.create(blockSize, this); //create the group descriptors groupCount = (int)Math.ceil((double)superblock.getBlocksCount() / (double)superblock.getBlocksPerGroup()); groupD... | 13,536 |
public void create(int blockSize) throws FileSystemException { try{ //create the superblock superblock = new Superblock(); superblock.create(blockSize, this); //create the group descriptors groupCount = (int)Math.ceil((double)superblock.getBlocksCount() / (double)superblock.getBlocksPerGroup()); groupD... | public void create(int blockSize) throws FileSystemException { try{ //create the superblock superblock = new Superblock(); superblock.create(blockSize, this); //create the group descriptors groupCount = (int)Math.ceil((double)superblock.getBlocksCount() / (double)superblock.getBlocksPerGroup()); groupD... | 13,537 |
public void create(int blockSize) throws FileSystemException { try{ //create the superblock superblock = new Superblock(); superblock.create(blockSize, this); //create the group descriptors groupCount = (int)Math.ceil((double)superblock.getBlocksCount() / (double)superblock.getBlocksPerGroup()); groupD... | public void create(int blockSize) throws FileSystemException { try{ //create the superblock superblock = new Superblock(); superblock.create(blockSize, this); //create the group descriptors groupCount = (int)Math.ceil((double)superblock.getBlocksCount() / (double)superblock.getBlocksPerGroup()); groupD... | 13,538 |
public void create(int blockSize) throws FileSystemException { try{ //create the superblock superblock = new Superblock(); superblock.create(blockSize, this); //create the group descriptors groupCount = (int)Math.ceil((double)superblock.getBlocksCount() / (double)superblock.getBlocksPerGroup()); groupD... | public void create(int blockSize) throws FileSystemException { try{ //create the superblock superblock = new Superblock(); superblock.create(blockSize, this); //create the group descriptors groupCount = (int)Math.ceil((double)superblock.getBlocksCount() / (double)superblock.getBlocksPerGroup()); groupD... | 13,539 |
protected INode createINode(int preferredBlockBroup, int fileFormat, int accessRights, int uid, int gid) throws FileSystemException, IOException { if(preferredBlockBroup >= superblock.getBlocksCount()) throw new FileSystemException("Block group "+preferredBlockBroup+" does not exist"); int groupNr = preferr... | protected INode createINode(int preferredBlockBroup, int fileFormat, int accessRights, int uid, int gid) throws FileSystemException, IOException { if(preferredBlockBroup >= superblock.getBlocksCount()) throw new FileSystemException("Block group "+preferredBlockBroup+" does not exist"); int groupNr = preferr... | 13,540 |
protected INode createINode(int preferredBlockBroup, int fileFormat, int accessRights, int uid, int gid) throws FileSystemException, IOException { if(preferredBlockBroup >= superblock.getBlocksCount()) throw new FileSystemException("Block group "+preferredBlockBroup+" does not exist"); int groupNr = preferr... | protected INode createINode(int preferredBlockBroup, int fileFormat, int accessRights, int uid, int gid) throws FileSystemException, IOException { if(preferredBlockBroup >= superblock.getBlocksCount()) throw new FileSystemException("Block group "+preferredBlockBroup+" does not exist"); int groupNr = preferr... | 13,541 |
public FSEntry createRootEntry() throws IOException { try{ return new Ext2Entry( getINode(Ext2Constants.EXT2_ROOT_INO), "/", Ext2Constants.EXT2_FT_DIR, this, null ); }catch(FileSystemException e) { throw new IOException(e); } } | public FSEntry createRootEntry() throws IOException { try{ return new Ext2Entry( getINode(Ext2Constants.EXT2_ROOT_INO), "/", Ext2Constants.EXT2_FT_DIR, this, null ); }catch(FileSystemException e) { throw new IOException(e); } } | 13,542 |
public BlockReservation findFreeBlocks(int group, long threshold) throws IOException{ GroupDescriptor gdesc = groupDescriptors[group]; //see if it's worth to check the block group at all if( gdesc.getFreeBlocksCount() < threshold) return new BlockReservation(false, -1, -1, gdesc.getFreeBlocksCount()); /* Retur... | public BlockReservation findFreeBlocks(int group, long threshold) throws IOException{ GroupDescriptor gdesc = groupDescriptors[group]; //see if it's worth to check the block group at all if( gdesc.getFreeBlocksCount() < threshold) return new BlockReservation(false, -1, -1, gdesc.getFreeBlocksCount()); /* Retur... | 13,543 |
public BlockReservation findFreeBlocks(int group, long threshold) throws IOException{ GroupDescriptor gdesc = groupDescriptors[group]; //see if it's worth to check the block group at all if( gdesc.getFreeBlocksCount() < threshold) return new BlockReservation(false, -1, -1, gdesc.getFreeBlocksCount()); /* Retur... | public BlockReservation findFreeBlocks(int group, long threshold) throws IOException{ GroupDescriptor gdesc = groupDescriptors[group]; //see if it's worth to check the block group at all if( gdesc.getFreeBlocksCount() < threshold) return new BlockReservation(false, -1, -1, gdesc.getFreeBlocksCount()); /* Retur... | 13,544 |
public BlockReservation findFreeBlocks(int group, long threshold) throws IOException{ GroupDescriptor gdesc = groupDescriptors[group]; //see if it's worth to check the block group at all if( gdesc.getFreeBlocksCount() < threshold) return new BlockReservation(false, -1, -1, gdesc.getFreeBlocksCount()); /* Retur... | public BlockReservation findFreeBlocks(int group, long threshold) throws IOException{ GroupDescriptor gdesc = groupDescriptors[group]; //see if it's worth to check the block group at all if( gdesc.getFreeBlocksCount() < threshold) return new BlockReservation(false, -1, -1, gdesc.getFreeBlocksCount()); /* Retur... | 13,545 |
public void flush() throws IOException { log.info("Flushing the contents of the filesystem"); //update the inodes synchronized(inodeCache) { try{ log.debug("inodecache size: "+inodeCache.size()); Iterator iterator = inodeCache.values().iterator(); while(iterator.hasNext()) { INode iNode = (INode)iter... | public void flush() throws IOException { log.info("Flushing the contents of the filesystem"); //update the inodes synchronized(inodeCache) { try{ log.debug("inodecache size: "+inodeCache.size()); Iterator iterator = inodeCache.values().iterator(); while(iterator.hasNext()) { INode iNode = (INode)iter... | 13,546 |
public void freeBlock(long blockNr) throws FileSystemException, IOException{ if(blockNr<0 || blockNr>=superblock.getBlocksCount()) throw new FileSystemException("Attempt to free nonexisting block ("+blockNr+")"); int group = translateToGroup(blockNr); int index = translateToIndex(blockNr); GroupDescriptor gde... | public void freeBlock(long blockNr) throws FileSystemException, IOException{ if(blockNr<0 || blockNr>=superblock.getBlocksCount()) throw new FileSystemException("Attempt to free nonexisting block ("+blockNr+")"); int group = translateToGroup(blockNr); int index = translateToIndex(blockNr); GroupDescriptor gde... | 13,547 |
public void freeBlock(long blockNr) throws FileSystemException, IOException{ if(blockNr<0 || blockNr>=superblock.getBlocksCount()) throw new FileSystemException("Attempt to free nonexisting block ("+blockNr+")"); int group = translateToGroup(blockNr); int index = translateToIndex(blockNr); GroupDescriptor gde... | public void freeBlock(long blockNr) throws FileSystemException, IOException{ if(blockNr<0 || blockNr>=superblock.getBlocksCount()) throw new FileSystemException("Attempt to free nonexisting block ("+blockNr+")"); int group = translateToGroup(blockNr); int index = translateToIndex(blockNr); GroupDescriptor gde... | 13,548 |
public void freeBlock(long blockNr) throws FileSystemException, IOException{ if(blockNr<0 || blockNr>=superblock.getBlocksCount()) throw new FileSystemException("Attempt to free nonexisting block ("+blockNr+")"); int group = translateToGroup(blockNr); int index = translateToIndex(blockNr); GroupDescriptor gde... | public void freeBlock(long blockNr) throws FileSystemException, IOException{ if(blockNr<0 || blockNr>=superblock.getBlocksCount()) throw new FileSystemException("Attempt to free nonexisting block ("+blockNr+")"); int group = translateToGroup(blockNr); int index = translateToIndex(blockNr); GroupDescriptor gde... | 13,549 |
public INode getINode(int iNodeNr) throws IOException, FileSystemException{ if((iNodeNr<1)||(iNodeNr>superblock.getINodesCount())) throw new FileSystemException("INode number ("+iNodeNr+") out of range (0-"+superblock.getINodesCount()+")"); Integer key=new Integer(iNodeNr); log.debug("iNodeCache size: "+inod... | public INode getINode(int iNodeNr) throws IOException, FileSystemException{ if((iNodeNr<1)||(iNodeNr>superblock.getINodesCount())) throw new FileSystemException("INode number ("+iNodeNr+") out of range (0-"+superblock.getINodesCount()+")"); Integer key=new Integer(iNodeNr); log.debug("iNodeCache size: "+inod... | 13,550 |
public INode getINode(int iNodeNr) throws IOException, FileSystemException{ if((iNodeNr<1)||(iNodeNr>superblock.getINodesCount())) throw new FileSystemException("INode number ("+iNodeNr+") out of range (0-"+superblock.getINodesCount()+")"); Integer key=new Integer(iNodeNr); log.debug("iNodeCache size: "+inod... | public INode getINode(int iNodeNr) throws IOException, FileSystemException{ if((iNodeNr<1)||(iNodeNr>superblock.getINodesCount())) throw new FileSystemException("INode number ("+iNodeNr+") out of range (0-"+superblock.getINodesCount()+")"); Integer key=new Integer(iNodeNr); log.debug("iNodeCache size: "+inod... | 13,551 |
public INode getINode(int iNodeNr) throws IOException, FileSystemException{ if((iNodeNr<1)||(iNodeNr>superblock.getINodesCount())) throw new FileSystemException("INode number ("+iNodeNr+") out of range (0-"+superblock.getINodesCount()+")"); Integer key=new Integer(iNodeNr); log.debug("iNodeCache size: "+inod... | public INode getINode(int iNodeNr) throws IOException, FileSystemException{ if((iNodeNr<1)||(iNodeNr>superblock.getINodesCount())) throw new FileSystemException("INode number ("+iNodeNr+") out of range (0-"+superblock.getINodesCount()+")"); Integer key=new Integer(iNodeNr); log.debug("iNodeCache size: "+inod... | 13,552 |
public void read() throws FileSystemException { byte data[]; try { data = new byte[Superblock.SUPERBLOCK_LENGTH]; //skip the first 1024 bytes (bootsector) and read the superblock //TODO: the superblock should read itself getApi().read(1024, data, 0, Superblock.SUPERBLOCK_LENGTH); //superblock = new Superb... | public void read() throws FileSystemException { byte data[]; try { data = new byte[Superblock.SUPERBLOCK_LENGTH]; //skip the first 1024 bytes (bootsector) and read the superblock //TODO: the superblock should read itself getApi().read(1024, data, 0, Superblock.SUPERBLOCK_LENGTH); //superblock = new Superb... | 13,553 |
public void read() throws FileSystemException { byte data[]; try { data = new byte[Superblock.SUPERBLOCK_LENGTH]; //skip the first 1024 bytes (bootsector) and read the superblock //TODO: the superblock should read itself getApi().read(1024, data, 0, Superblock.SUPERBLOCK_LENGTH); //superblock = new Superb... | public void read() throws FileSystemException { byte data[]; try { data = new byte[Superblock.SUPERBLOCK_LENGTH]; //skip the first 1024 bytes (bootsector) and read the superblock //TODO: the superblock should read itself getApi().read(1024, data, 0, Superblock.SUPERBLOCK_LENGTH); //superblock = new Superb... | 13,554 |
public BlockReservation testAndSetBlock(long blockNr) throws IOException{ if(blockNr<superblock.getFirstDataBlock() || blockNr>=superblock.getBlocksCount()) return new BlockReservation(false, -1, -1); int group = translateToGroup(blockNr); int index = translateToIndex(blockNr); /* Return false if the block is no... | public BlockReservation testAndSetBlock(long blockNr) throws IOException{ if(blockNr<superblock.getFirstDataBlock() || blockNr>=superblock.getBlocksCount()) return new BlockReservation(false, -1, -1); int group = translateToGroup(blockNr); int index = translateToIndex(blockNr); /* Return false if the block is no... | 13,555 |
public BlockReservation testAndSetBlock(long blockNr) throws IOException{ if(blockNr<superblock.getFirstDataBlock() || blockNr>=superblock.getBlocksCount()) return new BlockReservation(false, -1, -1); int group = translateToGroup(blockNr); int index = translateToIndex(blockNr); /* Return false if the block is no... | public BlockReservation testAndSetBlock(long blockNr) throws IOException{ if(blockNr<superblock.getFirstDataBlock() || blockNr>=superblock.getBlocksCount()) return new BlockReservation(false, -1, -1); int group = translateToGroup(blockNr); int index = translateToIndex(blockNr); /* Return false if the block is no... | 13,556 |
public BlockReservation testAndSetBlock(long blockNr) throws IOException{ if(blockNr<superblock.getFirstDataBlock() || blockNr>=superblock.getBlocksCount()) return new BlockReservation(false, -1, -1); int group = translateToGroup(blockNr); int index = translateToIndex(blockNr); /* Return false if the block is no... | public BlockReservation testAndSetBlock(long blockNr) throws IOException{ if(blockNr<superblock.getFirstDataBlock() || blockNr>=superblock.getBlocksCount()) return new BlockReservation(false, -1, -1); int group = translateToGroup(blockNr); int index = translateToIndex(blockNr); /* Return false if the block is no... | 13,557 |
public void writeBlock(long nr, byte[] data, boolean forceWrite) throws IOException { if(isClosed()) throw new IOException("FS closed"); if(isReadOnly()) throw new ReadOnlyFileSystemException("Filesystem is mounted read-only!"); Block block; Integer key=new Integer((int)nr); int blockSize=superblock.get... | public void writeBlock(long nr, byte[] data, boolean forceWrite) throws IOException { if(isClosed()) throw new IOException("FS closed"); if(isReadOnly()) throw new ReadOnlyFileSystemException("Filesystem is mounted read-only!"); Block block; Integer key=new Integer((int)nr); int blockSize=superblock.get... | 13,558 |
public void writeBlock(long nr, byte[] data, boolean forceWrite) throws IOException { if(isClosed()) throw new IOException("FS closed"); if(isReadOnly()) throw new ReadOnlyFileSystemException("Filesystem is mounted read-only!"); Block block; Integer key=new Integer((int)nr); int blockSize=superblock.get... | public void writeBlock(long nr, byte[] data, boolean forceWrite) throws IOException { if(isClosed()) throw new IOException("FS closed"); if(isReadOnly()) throw new ReadOnlyFileSystemException("Filesystem is mounted read-only!"); Block block; Integer key=new Integer((int)nr); int blockSize=superblock.get... | 13,559 |
ProcessingInstructionNode(TemplateNode children, TemplateNode next, String name) { super(children, next); this.name = name; } | ProcessingInstructionNode(TemplateNode children, TemplateNode next, String name) { super(children, next); this.name = name; } | 13,560 |
ProcessingInstructionNode(TemplateNode children, TemplateNode next, String name) { super(children, next); this.name = name; } | ProcessingInstructionNode(TemplateNode children, TemplateNode next, String name) { this.name = name; } | 13,561 |
TemplateNode clone(Stylesheet stylesheet) { return new ProcessingInstructionNode((children == null) ? null : children.clone(stylesheet), (next == null) ? null : next.clone(stylesheet), ... | TemplateNode clone(Stylesheet stylesheet) { return new ProcessingInstructionNode((children == null) ? null : children.clone(stylesheet), (next == null) ? null : next.clone(stylesheet), ... | 13,562 |
public Container getContainer() { View parent = getParent(); if (parent == null) throw new AssertionError("The parent of a View must not be null."); return parent.getContainer(); } | public Container getContainer() { View parent = getParent(); if (parent == null) return null; else return parent.getContainer(); } | 13,564 |
protected final Item clone(EmitterContext ec) { final Item res; final AbstractX86Stream os = ec.getStream(); switch (getKind()) { case Kind.REGISTER: final X86RegisterPool pool = ec.getPool(); final Register lsb = pool.request(JvmType.INT); final Register msb = pool.request(JvmType.INT); os.writeMOV(INTSIZ... | protected final Item clone(EmitterContext ec) { final DoubleWordItem res; final AbstractX86Stream os = ec.getStream(); switch (getKind()) { case Kind.REGISTER: final X86RegisterPool pool = ec.getPool(); final Register lsb = pool.request(JvmType.INT); final Register msb = pool.request(JvmType.INT); os.write... | 13,565 |
protected final Item clone(EmitterContext ec) { final Item res; final AbstractX86Stream os = ec.getStream(); switch (getKind()) { case Kind.REGISTER: final X86RegisterPool pool = ec.getPool(); final Register lsb = pool.request(JvmType.INT); final Register msb = pool.request(JvmType.INT); os.writeMOV(INTSIZ... | protected final Item clone(EmitterContext ec) { final Item res; final AbstractX86Stream os = ec.getStream(); switch (getKind()) { case Kind.REGISTER: final X86RegisterPool pool = ec.getPool(); final Register lsb = pool.request(JvmType.INT); final Register msb = pool.request(JvmType.INT); os.writeMOV(INTSIZ... | 13,566 |
protected final Item clone(EmitterContext ec) { final Item res; final AbstractX86Stream os = ec.getStream(); switch (getKind()) { case Kind.REGISTER: final X86RegisterPool pool = ec.getPool(); final Register lsb = pool.request(JvmType.INT); final Register msb = pool.request(JvmType.INT); os.writeMOV(INTSIZ... | protected final Item clone(EmitterContext ec) { final Item res; final AbstractX86Stream os = ec.getStream(); switch (getKind()) { case Kind.REGISTER: final X86RegisterPool pool = ec.getPool(); final Register lsb = pool.request(JvmType.INT); final Register msb = pool.request(JvmType.INT); os.writeMOV(INTSIZ... | 13,567 |
public Class[] getExceptionTypes() { if (exceptionTypes == null) { final VmExceptions exceptions = vmMethod.getExceptions(); final int cnt = exceptions.getLength(); final ArrayList list = new ArrayList(cnt); for (int i = 0; i < cnt; i++) { try { list.add(exceptions.getException(i).getRe... | public Class[] getExceptionTypes() { if (exceptionTypes == null) { final VmExceptions exceptions = vmMethod.getExceptions(); final int cnt = exceptions.getLength(); final ArrayList<Class> list = new ArrayList<Class>(cnt); for (int i = 0; i < cnt; i++) { try { list.add(exceptions.getExce... | 13,568 |
public Class[] getParameterTypes() { if (parameterTypes == null) { int cnt = vmMethod.getNoArguments(); ArrayList list = new ArrayList(cnt); for (int i = 0; i < cnt; i++) { list.add(vmMethod.getArgumentType(i).asClass()); } parameterTypes = list; } return (Class[])parameterTypes.toArray(new Class[param... | public Class[] getParameterTypes() { if (parameterTypes == null) { int cnt = vmMethod.getNoArguments(); ArrayList<Class> list = new ArrayList<Class>(cnt); for (int i = 0; i < cnt; i++) { list.add(vmMethod.getArgumentType(i).asClass()); } parameterTypes = list; } return (Class[])parameterTypes.toArray(n... | 13,569 |
public int hashCode() { return getDeclaringClass().getName().hashCode() ^ getName().hashCode(); } | public int hashCode() { final Class<?> declClass = getDeclaringClass(); return declClass.getName().hashCode() ^ getName().hashCode(); } | 13,570 |
public String toString() { // 128 is a reasonable buffer initial size for constructor StringBuffer sb = new StringBuffer(128); Modifier.toString(getModifiers(), sb).append(' '); sb.append(getReturnType().getName()).append(' '); sb.append(getDeclaringClass().getName()).append('.'); sb.append(getName()).append('('... | public String toString() { // 128 is a reasonable buffer initial size for constructor StringBuffer sb = new StringBuffer(128); Modifier.toString(getModifiers(), sb).append(' '); sb.append(getReturnType().getName()).append(' '); sb.append(getDeclaringClass().getName()).append('.'); sb.append(getName()).append('('... | 13,571 |
public String toString() { // 128 is a reasonable buffer initial size for constructor StringBuffer sb = new StringBuffer(128); Modifier.toString(getModifiers(), sb).append(' '); sb.append(getReturnType().getName()).append(' '); sb.append(getDeclaringClass().getName()).append('.'); sb.append(getName()).append('('... | public String toString() { // 128 is a reasonable buffer initial size for constructor StringBuffer sb = new StringBuffer(128); Modifier.toString(getModifiers(), sb).append(' '); sb.append(getReturnType().getName()).append(' '); sb.append(getDeclaringClass().getName()).append('.'); sb.append(getName()).append('('... | 13,572 |
public JMenuItem() { // TODO } // JMenuItem() | public JMenuItem() { // TODO } // JMenuItem() | 13,573 |
public void addMenuDragMouseListener(MenuDragMouseListener listener) { // TODO } // addMenuDragMouseListener() | public void addMenuDragMouseListener(MenuDragMouseListener listener) { // TODO } // addMenuDragMouseListener() | 13,574 |
public void addMenuKeyListener(MenuKeyListener listener) { // TODO } // addMenuKeyListener() | public void addMenuKeyListener(MenuKeyListener listener) { // TODO } // addMenuKeyListener() | 13,575 |
protected void configurePropertiesFromAction(Action action) { // TODO } // configurePropertiesFromAction() | protected void configurePropertiesFromAction(Action action) { // TODO } // configurePropertiesFromAction() | 13,576 |
protected PropertyChangeListener createActionPropertyChangeListener(Action action) { return null; // TODO } // createActionPropertyChangeListener() | protected PropertyChangeListener createActionPropertyChangeListener(Action action) { return null; // TODO } // createActionPropertyChangeListener() | 13,577 |
protected void fireMenuDragMouseDragged(MenuDragMouseEvent event) { // TODO } // fireMenuDragMouseDragged() | protected void fireMenuDragMouseDragged(MenuDragMouseEvent event) { // TODO } // fireMenuDragMouseDragged() | 13,578 |
protected void fireMenuDragMouseEntered(MenuDragMouseEvent event) { // TODO } // fireMenuDragMouseEntered() | protected void fireMenuDragMouseEntered(MenuDragMouseEvent event) { // TODO } // fireMenuDragMouseEntered() | 13,579 |
protected void fireMenuDragMouseExited(MenuDragMouseEvent event) { // TODO } // fireMenuDragMouseExited() | protected void fireMenuDragMouseExited(MenuDragMouseEvent event) { // TODO } // fireMenuDragMouseExited() | 13,580 |
protected void fireMenuDragMouseReleased(MenuDragMouseEvent event) { // TODO } // fireMenuDragMouseReleased() | protected void fireMenuDragMouseReleased(MenuDragMouseEvent event) { // TODO } // fireMenuDragMouseReleased() | 13,581 |
public KeyStroke getAccelerator() { return null; // TODO } // getAccelerator() | public KeyStroke getAccelerator() { return null; // TODO } // getAccelerator() | 13,582 |
public AccessibleContext getAccessibleContext() { if (accessibleContext == null) { accessibleContext = new AccessibleJMenuItem(this); } // if return accessibleContext; } // getAccessibleContext() | public AccessibleContext getAccessibleContext() { if (accessibleContext == null) { accessibleContext = new AccessibleJMenuItem(this); } // if return accessibleContext; } // getAccessibleContext() | 13,583 |
public AccessibleContext getAccessibleContext() { if (accessibleContext == null) { accessibleContext = new AccessibleJMenuItem(this); } // if return accessibleContext; } // getAccessibleContext() | public AccessibleContext getAccessibleContext() { if (accessibleContext == null) { accessibleContext = new AccessibleJMenuItem(this); // if return accessibleContext; // getAccessibleContext() | 13,584 |
public MenuElement[] getSubElements() { return null; // TODO } // getSubElements() | public MenuElement[] getSubElements() { return null; // TODO } // getSubElements() | 13,585 |
public boolean isArmed() { return false; // TODO } // isArmed() | public boolean isArmed() { return false; // TODO } // isArmed() | 13,586 |
public void menuSelectionChanged(boolean changed) { // TODO } // menuSelectionChanged() | public void menuSelectionChanged(boolean changed) { // TODO } // menuSelectionChanged() | 13,587 |
protected String paramString() { return null; // TODO } // paramString() | protected String paramString() { return null; // TODO } // paramString() | 13,588 |
public void processMenuDragMouseEvent(MenuDragMouseEvent event) { // TODO } // processMenuDragMouseEvent() | public void processMenuDragMouseEvent(MenuDragMouseEvent event) { // TODO } // processMenuDragMouseEvent() | 13,589 |
public void processMouseEvent(MouseEvent event, MenuElement[] path, MenuSelectionManager manager) { // TODO } // processMouseEvent() | public void processMouseEvent(MouseEvent event, MenuElement[] path, MenuSelectionManager manager) { // TODO } // processMouseEvent() | 13,590 |
public void removeMenuDragMouseListener(MenuDragMouseListener listener) { // TODO } // removeMenuDragMouseListener() | public void removeMenuDragMouseListener(MenuDragMouseListener listener) { // TODO } // removeMenuDragMouseListener() | 13,591 |
public void removeMenuKeyListener(MenuKeyListener listener) { // TODO } // removeMenuKeyListener() | public void removeMenuKeyListener(MenuKeyListener listener) { // TODO } // removeMenuKeyListener() | 13,592 |
public void setAccelerator(KeyStroke keystroke) { // TODO } // setAccelerator() | public void setAccelerator(KeyStroke keystroke) { // TODO } // setAccelerator() | 13,593 |
public void setArmed(boolean armed) { // TODO } // setArmed() | public void setArmed(boolean armed) { // TODO } // setArmed() | 13,594 |
public void setEnabled(boolean enabled) { // TODO } // setEnabled() | public void setEnabled(boolean enabled) { // TODO } // setEnabled() | 13,595 |
public void updateUI() { setUI((MenuItemUI) UIManager.get(this)); invalidate(); } // updateUI() | public void updateUI() { setUI((MenuItemUI) UIManager.get(this)); invalidate(); } // updateUI() | 13,596 |
public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) { // With the OceanTheme the button border is painted entirely different. // However, I couldn't figure out how this is determined besides checking // for instanceof OceanTheme. The button paint... | public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) { // With the OceanTheme the button border is painted entirely different. // However, I couldn't figure out how this is determined besides checking // for instanceof OceanTheme. The button paint... | 13,597 |
public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) { // With the OceanTheme the button border is painted entirely different. // However, I couldn't figure out how this is determined besides checking // for instanceof OceanTheme. The button paint... | public void paintBorder(Component c, Graphics g, int x, int y, int w, int h) { // With the OceanTheme the button border is painted entirely different. // However, I couldn't figure out how this is determined besides checking // for instanceof OceanTheme. The button paint... | 13,598 |
private void paintOceanButtonBorder(Component c, Graphics g, int x, int y, int w, int h) { ButtonModel bmodel = null; if (c instanceof AbstractButton) bmodel = ((AbstractButton) c).getModel(); Color darkShadow = MetalLookAndFeel.getControlDarkSha... | private void paintOceanButtonBorder(Component c, Graphics g, int x, int y, int w, int h) { ButtonModel bmodel = null; if (c instanceof AbstractButton) bmodel = ((AbstractButton) c).getModel(); Color darkShadow = MetalLookAndFeel.getControlDarkSha... | 13,599 |
private void paintOceanButtonBorder(Component c, Graphics g, int x, int y, int w, int h) { ButtonModel bmodel = null; if (c instanceof AbstractButton) bmodel = ((AbstractButton) c).getModel(); Color darkShadow = MetalLookAndFeel.getControlDarkSha... | private void paintOceanButtonBorder(Component c, Graphics g, int x, int y, int w, int h) { ButtonModel bmodel = null; if (c instanceof AbstractButton) bmodel = ((AbstractButton) c).getModel(); Color darkShadow = MetalLookAndFeel.getControlDarkSha... | 13,600 |
public CombinedClassLoader(Collection a_loaders) { ArrayList sLoaders = new ArrayList(a_loaders.size()); Iterator iter = a_loaders.iterator(); Object cl; while (iter.hasNext()) { cl = iter.next(); if (!sLoaders.contains(cl)) sLoaders.add(cl); } loaders = new Cl... | public CombinedClassLoader(Collection a_loaders) { ArrayList sLoaders = new ArrayList(a_loaders.size()); Iterator iter = a_loaders.iterator(); Object cl; while (iter.hasNext()) { cl = iter.next(); if (cl!=null && !sLoaders.contains(cl)) sLoaders.add(cl); } load... | 13,601 |
public void read(long fileOffset, byte[] dest, int off, int len) throws IOException { //synchronize to the inode cache to make sure that the inode does not get //flushed between reading it and locking it synchronized(((Ext2FileSystem)getFileSystem()).getInodeCache()) { //reread the inode before synchronizing to i... | public void read(long fileOffset, byte[] dest, int off, int len) throws IOException { //synchronize to the inode cache to make sure that the inode does not get //flushed between reading it and locking it synchronized(((Ext2FileSystem)getFileSystem()).getInodeCache()) { //reread the inode before synchronizing to i... | 13,602 |
private void rereadInode() throws IOException{ int iNodeNr = iNode.getINodeNr(); try{ iNode = ((Ext2FileSystem)getFileSystem()).getINode(iNodeNr); }catch(FileSystemException fse) { throw new IOException(fse); } } | private void rereadInode() throws IOException{ int iNodeNr = iNode.getINodeNr(); try{ iNode = ((Ext2FileSystem)getFileSystem()).getINode(iNodeNr); }catch(FileSystemException fse) { throw new IOException(fse); } } | 13,603 |
public void setLength(long length) throws IOException { if(!canWrite()) throw new ReadOnlyFileSystemException("FileSystem or File is readonly"); long blockSize = iNode.getExt2FileSystem().getBlockSize(); //synchronize to the inode cache to make sure that the inode does not get //flushed between reading it and... | public void setLength(long length) throws IOException { if(!canWrite()) throw new ReadOnlyFileSystemException("FileSystem or File is readonly"); long blockSize = iNode.getExt2FileSystem().getBlockSize(); //synchronize to the inode cache to make sure that the inode does not get //flushed between reading it and... | 13,604 |
public void write(long fileOffset, byte[] src, int off, int len) throws IOException { //synchronize to the inode cache to make sure that the inode does not get //flushed between reading it and locking it synchronized(((Ext2FileSystem)getFileSystem()).getInodeCache()) { //reread the inode before synchronizing to i... | public void write(long fileOffset, byte[] src, int off, int len) throws IOException { //synchronize to the inode cache to make sure that the inode does not get //flushed between reading it and locking it synchronized(((Ext2FileSystem)getFileSystem()).getInodeCache()) { //reread the inode before synchronizing to i... | 13,605 |
public static Remote toStub(Remote obj) throws NoSuchObjectException { Class cls = obj.getClass(); String classname = cls.getName(); ClassLoader cl = cls.getClassLoader(); try { Class scls = cl.loadClass(classname + "_Stub"); // JDK 1.2 stubs Class[] stubprototype = new Class[] { RemoteRef.class }... | public static Remote toStub(Remote obj) throws NoSuchObjectException { Class cls = obj.getClass(); String classname = cls.getName(); ClassLoader cl = cls.getClassLoader(); try { Class scls = cl.loadClass(classname + "_Stub"); // JDK 1.2 stubs Class[] stubprototype = new Class[] { RemoteRef.class }... | 13,606 |
public static UserException readUserException(String idl, InputStream input) { try { String holder = toHelperName(idl); Class holderClass = Class.forName(holder); Method read = holderClass.getMethod("read", new Class[] ... | public static UserException readUserException(String idl, InputStream input) { try { String holder = toHelperName(idl); Class holderClass = Class.forName(holder); Method read = holderClass.getMethod("read", new Class[] ... | 13,609 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.