bugged
stringlengths
6
599k
fixed
stringlengths
10
599k
__index_level_0__
int64
0
1.13M
protected synchronized boolean hasUnsatisifiedServiceDependencies() { boolean unsatisfiedServices = false; for (Iterator i = dependencies.iterator(); i.hasNext();) { String filter = null; String clazz = (String) i.next(); try { ServiceReference[] serviceReferences = getBundleContext().getServiceReferen...
protected synchronized boolean hasUnsatisifiedServiceDependencies() { boolean unsatisfiedServices = false; for (Iterator i = dependencies.iterator(); i.hasNext();) { String filter = null; String clazz = (String) i.next(); try { ServiceReference[] serviceReferences = getBundleContext().getServiceReferen...
1,101,310
public synchronized void serviceChanged(ServiceEvent serviceEvent) { if (dependencies.isEmpty()) { // already completed. return; } String[] classes = (String[]) serviceEvent.getServiceReference() .getProperty(Constants.OBJECTCLASS); switch (serviceEvent.getType()) { case ServiceEvent.REGISTERED: for (int...
public synchronized void serviceChanged(ServiceEvent serviceEvent) { if (unsatisfiedDependencies.isEmpty()) { // already completed. return; } String[] classes = (String[]) serviceEvent.getServiceReference() .getProperty(Constants.OBJECTCLASS); switch (serviceEvent.getType()) { case ServiceEvent.REGISTERED: ...
1,101,311
public synchronized void serviceChanged(ServiceEvent serviceEvent) { if (dependencies.isEmpty()) { // already completed. return; } String[] classes = (String[]) serviceEvent.getServiceReference() .getProperty(Constants.OBJECTCLASS); switch (serviceEvent.getType()) { case ServiceEvent.REGISTERED: for (int...
public synchronized void serviceChanged(ServiceEvent serviceEvent) { if (dependencies.isEmpty()) { // already completed. return; } String[] classes = (String[]) serviceEvent.getServiceReference() .getProperty(Constants.OBJECTCLASS); switch (serviceEvent.getType()) { case ServiceEvent.REGISTERED: for (int...
1,101,312
public synchronized void serviceChanged(ServiceEvent serviceEvent) { if (dependencies.isEmpty()) { // already completed. return; } String[] classes = (String[]) serviceEvent.getServiceReference() .getProperty(Constants.OBJECTCLASS); switch (serviceEvent.getType()) { case ServiceEvent.REGISTERED: for (int...
public synchronized void serviceChanged(ServiceEvent serviceEvent) { if (dependencies.isEmpty()) { // already completed. return; }else { registerListener(); } String[] classes = (String[]) serviceEvent.getServiceReference() .getProperty(Constants.OBJECTCLASS); switch (serviceEvent.getType()) { case ServiceE...
1,101,313
protected void addCapabilities( final Collection caps ) { caps.add( Capability.CREATE ); caps.add( Capability.DELETE ); caps.add( Capability.GET_TYPE ); caps.add( Capability.LAST_MODIFIED ); caps.add( Capability.LIST_CHILDREN ); caps.add( Capability.READ_CONTENT ); ...
protected void addCapabilities( final Collection caps ) { caps.add( Capability.CREATE ); caps.add( Capability.DELETE ); caps.add( Capability.GET_TYPE ); caps.add( Capability.GET_LAST_MODIFIED ); caps.add( Capability.LIST_CHILDREN ); caps.add( Capability.READ_CONTENT ); ...
1,101,314
public String toString() { return "JDBCConnection{" + (con == null ? "" : con.getClass()) + '}'; }
public String toString() { return "JDBCConnection{" + (con == null ? "" : con.getClass().getName()) + "}, "+getDialectIdentifier(); }
1,101,315
public static File getTestDirectory() { if (baseDir == null) { final String baseDirProp = System.getProperty("test.basedir"); baseDir = getCanonicalFile(new File(baseDirProp)); } return baseDir; }
public static String getTestDirectory() { if (baseDir == null) { final String baseDirProp = System.getProperty("test.basedir"); baseDir = getCanonicalFile(new File(baseDirProp)); } return baseDir; }
1,101,316
public static char[] getData(UserAuthenticationData data, UserAuthenticationData.Type type, char[] defaultValue) { if (data == null) { return defaultValue; } char[] ret = data.getData(type); if (ret == null) { return defaultValue; } return ret; }
public static char[] getData(UserAuthenticationData data, UserAuthenticationData.Type type, char[] overwriddenValue) { if (data == null) { return defaultValue; } char[] ret = data.getData(type); if (ret == null) { return defaultValue; } return ret; }
1,101,318
public static char[] getData(UserAuthenticationData data, UserAuthenticationData.Type type, char[] defaultValue) { if (data == null) { return defaultValue; } char[] ret = data.getData(type); if (ret == null) { return defaultValue; } return ret; }
public static char[] getData(UserAuthenticationData data, UserAuthenticationData.Type type, char[] defaultValue) { if (overwriddenValue != null) { return overwriddenValue; } if (data == null) { return defaultValue; } char[] ret = data.getData(type); if (ret == null) { return defaultValue; } return ret; }
1,101,319
public static char[] getData(UserAuthenticationData data, UserAuthenticationData.Type type, char[] defaultValue) { if (data == null) { return defaultValue; } char[] ret = data.getData(type); if (ret == null) { return defaultValue; } return ret; }
public static char[] getData(UserAuthenticationData data, UserAuthenticationData.Type type, char[] defaultValue) { if (data == null) { return null; } char[] ret = data.getData(type); if (ret == null) { return null; } return ret; }
1,101,320
public static char[] getData(UserAuthenticationData data, UserAuthenticationData.Type type, char[] defaultValue) { if (data == null) { return defaultValue; } char[] ret = data.getData(type); if (ret == null) { return defaultValue; } return ret; }
public static char[] getData(UserAuthenticationData data, UserAuthenticationData.Type type, char[] defaultValue) { if (data == null) { return defaultValue; } char[] ret = data.getData(type); if (ret == null) { return defaultValue; } return ret; }
1,101,321
public FileName parseUri(final VfsComponentContext context, FileName base, final String filename) throws FileSystemException { final StringBuffer name = new StringBuffer(); // Extract the scheme and authority parts final Authority auth = extractToPath(filename, name); // Decode and ad...
public FileName parseUri(final VfsComponentContext context, FileName base, final String filename) throws FileSystemException { final StringBuffer name = new StringBuffer(); // Extract the scheme and authority parts final Authority auth = extractToPath(filename, name); // Decode and ad...
1,101,322
public boolean build(AggregateTraceable primitives) { Timer t = new Timer(); t.start(); this.primitives = primitives; int n = primitives.numPrimitives(); // compute bounds bounds = primitives.getWorldBounds(null); // create grid from number of objects bounds.e...
public boolean build(PrimitiveList primitives) { Timer t = new Timer(); t.start(); this.primitives = primitives; int n = primitives.numPrimitives(); // compute bounds bounds = primitives.getWorldBounds(null); // create grid from number of objects bounds.enlarg...
1,101,324
public boolean build(AggregateTraceable primitives) { Timer t = new Timer(); t.start(); this.primitives = primitives; int n = primitives.numPrimitives(); // compute bounds bounds = primitives.getWorldBounds(null); // create grid from number of objects bounds.e...
public boolean build(AggregateTraceable primitives) { Timer t = new Timer(); t.start(); this.primitives = primitives; int n = primitives.getNumPrimitives(); // compute bounds bounds = primitives.getWorldBounds(null); // create grid from number of objects bound...
1,101,325
public boolean build(AggregateTraceable primitives) { Timer t = new Timer(); t.start(); this.primitives = primitives; int n = primitives.numPrimitives(); // compute bounds bounds = primitives.getWorldBounds(null); // create grid from number of objects bounds.e...
public boolean build(AggregateTraceable primitives) { Timer t = new Timer(); t.start(); this.primitives = primitives; int n = primitives.numPrimitives(); // compute bounds bounds = primitives.getWorldBounds(null); // create grid from number of objects bounds.e...
1,101,326
public void intersect(Ray r, Instance parent, IntersectionState state) { float intervalMin = r.getMin(); float intervalMax = r.getMax(); float orgX = r.ox; float dirX = r.dx, invDirX = 1 / dirX; float t1, t2; t1 = (bounds.getMinimum().x - orgX) * invDirX; t2 = (bound...
public void intersect(Ray r, IntersectionState state) { float intervalMin = r.getMin(); float intervalMax = r.getMax(); float orgX = r.ox; float dirX = r.dx, invDirX = 1 / dirX; float t1, t2; t1 = (bounds.getMinimum().x - orgX) * invDirX; t2 = (bounds.getMaximum().x ...
1,101,327
public void intersect(Ray r, Instance parent, IntersectionState state) { float intervalMin = r.getMin(); float intervalMax = r.getMax(); float orgX = r.ox; float dirX = r.dx, invDirX = 1 / dirX; float t1, t2; t1 = (bounds.getMinimum().x - orgX) * invDirX; t2 = (bound...
public void intersect(Ray r, Instance parent, IntersectionState state) { float intervalMin = r.getMin(); float intervalMax = r.getMax(); float orgX = r.ox; float dirX = r.dx, invDirX = 1 / dirX; float t1, t2; t1 = (bounds.getMinimum().x - orgX) * invDirX; t2 = (bound...
1,101,328
public static List<String> getColumn(final ResultSet rs, final int columnPos) { List<String> l = new ArrayList(); try { while (rs.next()) { l.add(rs.getString(columnPos)); } } catch (SQLException e) { throw new JDBCException(e); } re...
public static List<String> getColumn(final ResultSet rs, final int columnPos) { List<String> l = new ArrayList<String>(); try { while (rs.next()) { l.add(rs.getString(columnPos)); } } catch (SQLException e) { throw new JDBCException(e); } ...
1,101,330
public static void main(String[] args) { if (args.length > 0) { boolean showFrame = true; String sampler = "bucket"; boolean noRender = false; String filename = null; String input = null; String accel = null; int i = 0; i...
public static void main(String[] args) { if (args.length > 0) { boolean showFrame = true; String sampler = "bucket"; boolean noRender = false; String filename = null; String input = null; String accel = null; int i = 0; i...
1,101,331
public void init(final ConfigurationEl configuration, final ScriptsContext ctx) { final List<ConnectionEl> connections = configuration.getConnections(); for (ConnectionEl c : connections) { final ConnectionManager con = new ConnectionManager(ctx, c); con.getCo...
public void init(final ConfigurationEl configuration, final ScriptsContext ctx) { final List<ConnectionEl> connections = configuration.getConnections(); for (ConnectionEl c : connections) { final ConnectionManager con = new ConnectionManager(ctx, c); Connectio...
1,101,332
public void init(final ConfigurationEl configuration, final ScriptsContext ctx) { final List<ConnectionEl> connections = configuration.getConnections(); for (ConnectionEl c : connections) { final ConnectionManager con = new ConnectionManager(ctx, c); con.getCo...
public void init(final ConfigurationEl configuration, final ScriptsContext ctx) { final List<ConnectionEl> connections = configuration.getConnections(); for (ConnectionEl c : connections) { final ConnectionManager con = new ConnectionManager(ctx, c); con.getCo...
1,101,333
public void init(final ConfigurationEl configuration, final ScriptsContext ctx) { final List<ConnectionEl> connections = configuration.getConnections(); for (ConnectionEl c : connections) { final ConnectionManager con = new ConnectionManager(ctx, c); con.getCo...
public void init(final ConfigurationEl configuration, final ScriptsContext ctx) { final List<ConnectionEl> connections = configuration.getConnections(); for (ConnectionEl c : connections) { final ConnectionManager con = new ConnectionManager(ctx, c); con.getCo...
1,101,334
private void parseObjectBlock(SunflowAPI api) throws ParserException, IOException { p.checkNextToken("{"); String[] shaders = null; boolean multiShader = false; if (p.peekNextToken("shaders")) { int n = p.getNextInt(); shaders = new String[n]; for (int i ...
private void parseObjectBlock(SunflowAPI api) throws ParserException, IOException { p.checkNextToken("{"); String[] shaders = null; boolean multiShader = false; if (p.peekNextToken("shaders")) { int n = p.getNextInt(); shaders = new String[n]; for (int i ...
1,101,341
private void parseObjectBlock(SunflowAPI api) throws ParserException, IOException { p.checkNextToken("{"); String[] shaders = null; boolean multiShader = false; if (p.peekNextToken("shaders")) { int n = p.getNextInt(); shaders = new String[n]; for (int i ...
private void parseObjectBlock(SunflowAPI api) throws ParserException, IOException { p.checkNextToken("{"); String[] shaders = null; boolean multiShader = false; if (p.peekNextToken("shaders")) { int n = p.getNextInt(); shaders = new String[n]; for (int i ...
1,101,342
protected String[] getApplicationContextLocations(Bundle bundle) { Dictionary manifestHeaders = bundle.getHeaders(); String contextLocationsHeader = (String) manifestHeaders.get(CONTEXT_LOCATION_HEADER); if (contextLocationsHeader != null) { String[] locs = StringUtils.tokenizeToStringArray(contextLocationsHeader...
protected String[] getApplicationContextLocations(Bundle bundle) { Dictionary manifestHeaders = bundle.getHeaders(); String contextLocationsHeader = (String) manifestHeaders.get(CONTEXT_LOCATION_HEADER); if (contextLocationsHeader != null) { String[] locs = StringUtils.tokenizeToStringArray(contextLocationsHeader...
1,101,343
public void testRootFolderExists() throws FileSystemException { FileObject root = manager.resolveFile("ram:///", defaultRamFs); assertTrue(root.getType().equals(FileType.FOLDER)); try { root.delete(); fail(); } catch (FileSystemException e) { } ...
public void testRootFolderExists() throws FileSystemException { FileObject root = manager.resolveFile("ram:///", defaultRamFs); assertTrue(root.getType().hasChildren()); try { root.delete(); fail(); } catch (FileSystemException e) { } }
1,101,344
public void intersect(Ray r, IntersectionState istate) { Ray localRay = r.transform(w2o); geometry.intersect(localRay, this, istate); // FIXME: transfer max distance to current ray r.setMax(localRay.getMax()); }
public void intersect(Ray r, IntersectionState state) { Ray localRay = r.transform(w2o); geometry.intersect(localRay, this, istate); // FIXME: transfer max distance to current ray r.setMax(localRay.getMax()); }
1,101,347
public void intersect(Ray r, IntersectionState istate) { Ray localRay = r.transform(w2o); geometry.intersect(localRay, this, istate); // FIXME: transfer max distance to current ray r.setMax(localRay.getMax()); }
public void intersect(Ray r, IntersectionState istate) { Ray localRay = r.transform(w2o); state.current = this; geometry.intersect(localRay, state); // FIXME: transfer max distance to current ray r.setMax(localRay.getMax()); }
1,101,348
public void prepareShadingState(ShadingState state) { geometry.prepareShadingState(this, state); }
public void prepareShadingState(ShadingState state) { geometry.prepareShadingState(state); }
1,101,349
public PrimitiveList tesselate() { float[] vertices = new float[patches.length * (subdivs + 1) * (subdivs + 1) * 3]; float[] normals = smooth ? new float[patches.length * (subdivs + 1) * (subdivs + 1) * 3] : null; float[] uvs = new float[patches.length * (subdivs + 1) * (subdivs + 1) * 2]; ...
public PrimitiveList tesselate() { float[] vertices = new float[patches.length * (subdivs + 1) * (subdivs + 1) * 3]; float[] normals = smooth ? new float[patches.length * (subdivs + 1) * (subdivs + 1) * 3] : null; float[] uvs = new float[patches.length * (subdivs + 1) * (subdivs + 1) * 2]; ...
1,101,350
protected long doGetContentSize() throws Exception { return url.openConnection().getContentLength(); }
protected long doGetContentSize() throws Exception { final URLConnection conn = url.openConnection(); final InputStream in = conn.getInputStream(); try { return conn.getContentLength(); } finally { in.close(); } }
1,101,351
protected long doGetLastModifiedTime() throws Exception { return url.openConnection().getLastModified(); }
protected long doGetLastModifiedTime() throws Exception { final URLConnection conn = url.openConnection(); final InputStream in = conn.getInputStream(); try { return conn.getLastModified(); } finally { in.close(); } }
1,101,352
protected FileType doGetType() throws Exception { // Attempt to connect try { url.openConnection().connect(); } catch ( final FileNotFoundException e ) { return FileType.IMAGINARY; } return FileType.FILE; }
protected FileType doGetType() throws Exception { // Attempt to connect try { final URLConnection conn = url.openConnection(); final InputStream in = conn.getInputStream(); try { if (conn instanceof HttpURLConnection) { final int status = ((HttpURLConnection)conn).getResponseCode(...
1,101,353
protected FileType doGetType() throws Exception { // Attempt to connect try { url.openConnection().connect(); } catch ( final FileNotFoundException e ) { return FileType.IMAGINARY; } return FileType.FILE; }
protected FileType doGetType() throws Exception { // Attempt to connect try { url.openConnection().connect(); } catch ( final FileNotFoundException e ) { return FileType.IMAGINARY; } }
1,101,354
public TreeModel getTreeModel(Set nounIDSet, Set<Concept> verbConceptSet, String type) { Set<List<Concept>> pathSet = treeMaker.getPathList(verbConceptSet); removeNounConceptPath(pathSet); trimmedConceptNum = 0; TreeModel propertyTreeModel = treeMaker.getTrimmedTreeModel(pathSet, project...
public TreeModel getTreeModel(Set nounIDSet, Set<Concept> verbConceptSet, String type) { Set<List<Concept>> pathSet = treeMaker.getPathList(verbConceptSet); removeNounConceptPath(pathSet); trimmedConceptNum = 0; TreeModel propertyTreeModel = treeMaker.getTrimmedTreeModel(pathSet, project...
1,101,355
private void parseImageBlock(SunflowAPI api) throws IOException, ParserException { p.checkNextToken("{"); p.checkNextToken("resolution"); api.parameter("resolutionX", p.getNextInt()); api.parameter("resolutionY", p.getNextInt()); p.checkNextToken("aa"); api.parameter("aa.mi...
private void parseImageBlock(SunflowAPI api) throws IOException, ParserException { p.checkNextToken("{"); p.checkNextToken("resolution"); api.parameter("resolutionX", p.getNextInt()); api.parameter("resolutionY", p.getNextInt()); p.checkNextToken("aa"); api.parameter("aa.mi...
1,101,356
private void configure(final String configUri) throws FileSystemException { try { // Load up the config // TODO - validate final DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); factory.setIgnoringElementContentWhitespace(true); ...
private void configure(final String configUri) throws FileSystemException { try { // Load up the config // TODO - validate final DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); factory.setIgnoringElementContentWhitespace(true); ...
1,101,359
public void test() throws EtlExecutorException { EtlExecutor etlExecutor = newEtlExecutor(); Connection c = getConnection("cancelTest"); final Thread etlThread = Thread.currentThread(); interrupted = false; new Thread() { public void run() { try { ...
public void test() throws EtlExecutorException { EtlExecutor etlExecutor = newEtlExecutor(); Connection c = getConnection("cancelTest"); final Thread etlThread = Thread.currentThread(); interrupted = false; new Thread() { public void run() { try { ...
1,101,360
public void test() throws EtlExecutorException { EtlExecutor etlExecutor = newEtlExecutor(); Connection c = getConnection("cancelTest"); final Thread etlThread = Thread.currentThread(); interrupted = false; new Thread() { public void run() { try { ...
public void test() throws EtlExecutorException { EtlExecutor etlExecutor = newEtlExecutor(); Connection c = getConnection("cancelTest"); final Thread etlThread = Thread.currentThread(); interrupted = false; new Thread() { public void run() { try { ...
1,101,361
public void processRow(final ParametersCallback parameters) { fail("Tables T1,T2 rows must be rolled back"); }
public void processRow(final ParametersCallback parameters) { assertEquals(0, parameters.getParameter("1")); }
1,101,362
public String getTargetHtmlLines(String word) { StringWriter writer = new StringWriter(); writer.write("<html><body>"); ListModel listModel = inputDocList.getModel(); for (int i = 0; i < listModel.getSize(); i++) { Document doc = (Document) listModel.getElementAt(i); ...
public String getTargetHtmlLines(String word) { StringWriter writer = new StringWriter(); writer.write("<html><body>"); ListModel listModel = inputDocList.getModel(); for (int i = 0; i < listModel.getSize(); i++) { Document doc = (Document) listModel.getElementAt(i); ...
1,101,365
public String getTargetHtmlLines(String word) { StringWriter writer = new StringWriter(); writer.write("<html><body>"); ListModel listModel = inputDocList.getModel(); for (int i = 0; i < listModel.getSize(); i++) { Document doc = (Document) listModel.getElementAt(i); ...
public String getTargetHtmlLines(String word) { StringWriter writer = new StringWriter(); writer.write("<html><body>"); ListModel listModel = inputDocList.getModel(); for (int i = 0; i < listModel.getSize(); i++) { Document doc = (Document) listModel.getElementAt(i); ...
1,101,366
public boolean parse(String filename, SunflowAPI api) { try { UI.printInfo("[RA3] Reading geometry: \"%s\" ...", filename); File file = new File(filename); FileInputStream stream = new FileInputStream(filename); MappedByteBuffer map = stream.getChannel().map(FileCh...
public boolean parse(String filename, SunflowAPI api) { try { UI.printInfo("[RA3] Reading geometry: \"%s\" ...", filename); File file = new File(filename); FileInputStream stream = new FileInputStream(filename); MappedByteBuffer map = stream.getChannel().map(FileCh...
1,101,368
public Connection connect(ConnectionParameters connectionParameters) { if (JANINO_NOT_FOUND!=null) { throw new JaninoProviderException("Janino not found on the class path. " + "Check if connection classpath attribute points to janino.jar", JANINO_NOT_FOUND); } retu...
public Connection connect(ConnectionParameters connectionParameters) { if (JANINO_NOT_FOUND!=null) { throw new JaninoProviderException("Janino not found on the class path. " + "Check if connection classpath attribute points to janino.jar", JANINO_NOT_FOUND); } retu...
1,101,369
public final void set(String name, Object value) { if (row == null) { row = new HashMap<String, Object>(); } row.put(name, value); }
public final void set(String name, Object value) { if (row == null) { row = new TreeMap<String, Object>(String.CASE_INSENSITIVE_ORDER); } row.put(name, value); }
1,101,370
public void init() throws FileSystemException { if ( replicatorComponent != null ) { try { AccessController.doPrivileged( new InitAction() ); } catch ( final PrivilegedActionException e ) { final String message = R...
public void init() throws FileSystemException { if ( replicatorComponent != null ) { try { AccessController.doPrivileged( new InitAction() ); } catch ( final PrivilegedActionException e ) { final String message = R...
1,101,371
public File replicateFile( FileObject srcFile, FileSelector selector ) throws FileSystemException { try { final ReplicateAction action = new ReplicateAction( srcFile, selector ); return (File)AccessController.doPrivileged( action ); } catch ( final Privile...
public File replicateFile( FileObject srcFile, FileSelector selector ) throws FileSystemException { try { final ReplicateAction action = new ReplicateAction( srcFile, selector ); return (File)AccessController.doPrivileged( action ); } catch ( final Privile...
1,101,372
public JarEntry getJarEntry() throws IOException { final String message = REZ.getString( "jar-entry-no-access.error" ); throw new UnsupportedOperationException( message ); }
public JarEntry getJarEntry() throws IOException { final String message = REZ.getString( "jar-entry-no-access.error" ); throw new UnsupportedOperationException( message ); }
1,101,373
public JarFile getJarFile() throws IOException { final String message = REZ.getString( "jar-file-no-access.error" ); throw new UnsupportedOperationException( message ); }
public JarFile getJarFile() throws IOException { final String message = REZ.getString( "jar-file-no-access.error" ); throw new UnsupportedOperationException( message ); }
1,101,374
TarBuffer( final InputStream input, final int blockSize, final int recordSize ) { m_input = input; initialize( blockSize, recordSize ); }
TarBuffer( final InputStream input, final int blockSize, final int recordSize ) { m_input = input; initialize( blockSize, recordSize ); }
1,101,375
TarBuffer( final InputStream input, final int blockSize, final int recordSize ) { m_input = input; initialize( blockSize, recordSize ); }
TarBuffer( final InputStream input, final int blockSize, final int recordSize ) { m_input = input; initialize( blockSize, recordSize ); }
1,101,376
public boolean isSatisfied() { ServiceReference[] refs; try { refs = getBundleContext().getServiceReferences(clazz, filter.toString()); } catch (InvalidSyntaxException e) { throw new IllegalStateException("Filter string '" ...
public boolean isSatisfied() { ServiceReference[] refs; try { refs = getBundleContext().getServiceReferences(clazz, filter.toString()); } catch (InvalidSyntaxException e) { throw (IllegalStateException)new IllegalStateException("Filter string '" ...
1,101,377
public boolean isSatisfied() { ServiceReference[] refs; try { refs = getBundleContext().getServiceReferences(clazz, filter.toString()); } catch (InvalidSyntaxException e) { throw new IllegalStateException("Filter string '" ...
public boolean isSatisfied() { ServiceReference[] refs; try { refs = getBundleContext().getServiceReferences(clazz, filter.toString()); } catch (InvalidSyntaxException e) { throw new IllegalStateException("Filter string '" ...
1,101,378
private Filter getFilter (String serviceInterface, String serviceFilter) { StringBuffer sb = new StringBuffer(); boolean andFilterWithInterfaceName = serviceFilter != null; if (andFilterWithInterfaceName) { sb.append("(&"); } if (serviceFilter != null) { sb.append(serviceFilter); } sb.append("("...
private Filter getFilter (String serviceInterface, String serviceFilter) { StringBuffer sb = new StringBuffer(); boolean andFilterWithInterfaceName = serviceFilter != null; if (andFilterWithInterfaceName) { sb.append("(&"); } if (serviceFilter != null) { sb.append(serviceFilter); } sb.append("("...
1,101,379
private Filter getFilter (String serviceInterface, String serviceFilter) { StringBuffer sb = new StringBuffer(); boolean andFilterWithInterfaceName = serviceFilter != null; if (andFilterWithInterfaceName) { sb.append("(&"); } if (serviceFilter != null) { sb.append(serviceFilter); } sb.append("("...
private Filter getFilter (String serviceInterface, String serviceFilter) { StringBuffer sb = new StringBuffer(); boolean andFilterWithInterfaceName = serviceFilter != null; if (andFilterWithInterfaceName) { sb.append("(&"); } if (serviceFilter != null) { sb.append(serviceFilter); } sb.append("("...
1,101,380
private void registerListener() { StringBuffer sb = new StringBuffer(100 * unsatisfiedDependencies.size()); sb.append("(|"); for (Iterator i = unsatisfiedDependencies.iterator(); i.hasNext();) { ((Dependency) i.next()).appendTo(sb); } sb.append(')'); String filte...
private void registerListener() { StringBuffer sb = new StringBuffer(100 * unsatisfiedDependencies.size()); sb.append("(|"); for (Iterator i = unsatisfiedDependencies.iterator(); i.hasNext();) { ((Dependency) i.next()).appendTo(sb); } sb.append(')'); String filte...
1,101,381
private void registerListener() { StringBuffer sb = new StringBuffer(100 * unsatisfiedDependencies.size()); sb.append("(|"); for (Iterator i = unsatisfiedDependencies.iterator(); i.hasNext();) { ((Dependency) i.next()).appendTo(sb); } sb.append(')'); String filte...
private void registerListener() { StringBuffer sb = new StringBuffer(100 * unsatisfiedDependencies.size()); sb.append("(|"); for (Iterator i = unsatisfiedDependencies.iterator(); i.hasNext();) { ((Dependency) i.next()).appendTo(sb); } sb.append(')'); String filte...
1,101,382
public Object getParameter(final String name) { if (ThisParameter.NAME.equals(name)) { return thisParameter; } return properties.get(name); }
public Object getParameter(final String name) { if (ThisParameter.NAME.equalsIgnoreCase(name)) { return thisParameter; } return properties.get(name); }
1,101,383
public Object getAttribute( String attrName ) throws FileSystemException { // TODO - implement this throw new FileSystemException( "Not implemented." ); }
public Object getAttribute( String attrName ) throws FileSystemException { // TODO - implement this return file.doGetAttribute( attrName ); }
1,101,384
public long getLastModifiedTime() throws FileSystemException { // TODO - implement this throw new FileSystemException( "Not implemented." ); }
public long getLastModifiedTime() throws FileSystemException { // TODO - implement this if( !file.exists() ) { final String message = REZ.getString( "get-last-modified-no-exist.error", file ); throw new FileSystemException( message ); } return file.doGetLastModifiedTime(); }
1,101,386
public void setAttribute( String attrName, Object value ) throws FileSystemException { // TODO - implement this throw new FileSystemException( "Not implemented." ); }
public void setAttribute( String attrName, Object value ) throws FileSystemException { // TODO - implement this file.doSetAttribute( attrName, value ); }
1,101,389
public void setLastModifiedTime( long modTime ) throws FileSystemException { // TODO - implement this throw new FileSystemException( "Not implemented." ); }
public void setLastModifiedTime( long modTime ) throws FileSystemException { // TODO - implement this if( !file.exists() ) { final String message = REZ.getString( "set-last-modified-no-exist.error", file ); throw new FileSystemException( message ); } file.doSetLastModifiedTime( modTime ); }
1,101,390
final void append(final Resource resource) { if (resource != null) { //If string rsource and we already have content if (resource != null && (resource instanceof StringResource) && !content.isEmpty()) { final int lastIndex = content.size() - 1; Resource las...
final void append(final Resource resource) { if (resource != null) { //If string rsource and we already have content if (resource instanceof StringResource && !content.isEmpty()) { final int lastIndex = content.size() - 1; Resource last = content.get(lastIn...
1,101,391
private SharedRandomContentInputStream(final FileObject fo, final long fileStart, final long start, final long end, final InputStream is) throws FileSystemException { super(is); if (!fo.getFileSystem().hasCapability(Capability.RANDOM_ACCESS_READ)) { throw new FileSystemException("vfs.util/missing-capability.error...
private SharedRandomContentInputStream(final FileObject fo, final long fileStart, final long fileEnd, final InputStream is) throws FileSystemException { super(is); if (!fo.getFileSystem().hasCapability(Capability.RANDOM_ACCESS_READ)) { throw new FileSystemException("vfs.util/missing-capability.error", Capability....
1,101,392
private SharedRandomContentInputStream(final FileObject fo, final long fileStart, final long start, final long end, final InputStream is) throws FileSystemException { super(is); if (!fo.getFileSystem().hasCapability(Capability.RANDOM_ACCESS_READ)) { throw new FileSystemException("vfs.util/missing-capability.error...
private SharedRandomContentInputStream(final FileObject fo, final long fileStart, final long start, final long end, final InputStream is) throws FileSystemException { super(is); if (!fo.getFileSystem().hasCapability(Capability.RANDOM_ACCESS_READ)) { throw new FileSystemException("vfs.util/missing-capability.error...
1,101,393
private boolean checkEnd() { return end > -1 && (start + pos) >= end; }
private boolean checkEnd() { return fileEnd > -1 && (getFilePosition() >= fileEnd); }
1,101,394
public InputStream newStream(long start, long end) { try { RandomAccessContent rac = fo.getContent().getRandomAccessContent(RandomAccessMode.READ); rac.seek(this.fileStart+start); return new SharedRandomContentInputStream(fo, this.fileStart+start, start, end, rac.getInputStream()); } catch (IOException e) {...
public InputStream newStream(long start, long end) { try { RandomAccessContent rac = fo.getContent().getRandomAccessContent(RandomAccessMode.READ); rac.seek(this.fileStart+start); return new SharedRandomContentInputStream(fo, this.fileStart+start, start, end, rac.getInputStream()); } catch (IOException e) {...
1,101,395
private int readNormalizedChar() throws IOException { for (int n;(n = reader.read())>=0;) { if (!keepFormat) { //Normalize char \r,\n->\n ; any whitespace transformed to space //If previous char was also a whitespace - this char is ignored if (n=='\n'...
private int readNormalizedChar() throws IOException { for (int n;(n = reader.read())>=0;) { if (!keepFormat) { //Normalize char \r,\n->\n ; any whitespace transformed to space //If previous char was also a whitespace - this char is ignored if (n=='\n'...
1,101,397
public SplashWindow() { ImageIcon logo = Utils.getImageIcon("doddle_splash.png"); JLabel logoLabel = new JLabel(logo); getContentPane().add(logoLabel, BorderLayout.CENTER); JLabel versionInfoLabel = new JLabel("Beta Version: " + DODDLE.VERSION); versionInfoLabel.setFont(versionInf...
public SplashWindow() { ImageIcon logo = Utils.getImageIcon("doddle_splash.png"); JLabel logoLabel = new JLabel(logo); getContentPane().add(logoLabel, BorderLayout.CENTER); JLabel versionInfoLabel = new JLabel("Beta Version: " + DODDLE.VERSION); versionInfoLabel.setFont(versionInf...
1,101,398
public SplashWindow() { ImageIcon logo = Utils.getImageIcon("doddle_splash.png"); JLabel logoLabel = new JLabel(logo); getContentPane().add(logoLabel, BorderLayout.CENTER); JLabel versionInfoLabel = new JLabel("Beta Version: " + DODDLE.VERSION); versionInfoLabel.setFont(versionInf...
public SplashWindow() { ImageIcon logo = Utils.getImageIcon("doddle_splash.png"); JLabel logoLabel = new JLabel(logo); getContentPane().add(logoLabel, BorderLayout.CENTER); JLabel versionInfoLabel = new JLabel("Beta Version: " + DODDLE.VERSION); versionInfoLabel.setFont(versionInf...
1,101,399
public void init() { registerBeanDefinitionParser("reference", new ReferenceBeanDefinitionParser()); registerBeanDefinitionParser("service", new ServiceBeanDefinitionParser()); registerBeanDefinitionParser("property-placeholder", new OsgiPropertyPlaceholderDefinitionParser()); registerBeanDefinitionParser("con...
public void init() { registerBeanDefinitionParser("reference", new ReferenceBeanDefinitionParser()); registerBeanDefinitionParser("service", new ServiceBeanDefinitionParser()); registerBeanDefinitionParser("property-placeholder", new OsgiPropertyPlaceholderDefinitionParser()); registerBeanDefinitionParser("con...
1,101,401
protected FileObject[] doListChildrenResolved() throws Exception { doAttach(); WebdavResource[] children = new org.apache.webdav.lib.WebdavResource[0]; try { children = resource.listWebdavResources(); } catch (HttpException e) { if (e.getReas...
protected FileObject[] doListChildrenResolved() throws Exception { doAttach(); WebdavResource[] children = new org.apache.webdav.lib.WebdavResource[0]; try { children = resource.listWebdavResources(); } catch (HttpException e) { if (e.getReas...
1,101,402
protected FileObject[] doListChildrenResolved() throws Exception { doAttach(); WebdavResource[] children = new org.apache.webdav.lib.WebdavResource[0]; try { children = resource.listWebdavResources(); } catch (HttpException e) { if (e.getReas...
protected FileObject[] doListChildrenResolved() throws Exception { doAttach(); WebdavResource[] children = new org.apache.webdav.lib.WebdavResource[0]; try { children = resource.listWebdavResources(); } catch (HttpException e) { if (e.getReas...
1,101,403
private void processParentDavResource() throws FileSystemException { WebdavFileObject parent = (WebdavFileObject) getParent(); try { // after this our resource should be reset parent.doListChildrenResolved(); } catch (Exception e) { throw...
private void processParentDavResource() throws FileSystemException { WebdavFileObject parent = (WebdavFileObject) FileObjectUtils.getAbstractFileObject(getParent()); try { // after this our resource should be reset parent.doListChildrenResolved(); } catch ...
1,101,404
public void testGetEntry() throws Exception { assertNotNull(mock.getEntry(MockBundleTest.class.getPackage().getName().replace(".", "/") + "/MockBundleTest.class")); }
public void testGetEntry() throws Exception { assertNotNull(mock.getEntry(MockBundleTest.class.getPackage().getName().replace('.', '/') + "/MockBundleTest.class")); }
1,101,405
public void testGetResource() { assertNotNull(mock.getResource(MockBundleTest.class.getPackage().getName().replace(".", "/") + "/MockBundleTest.class")); }
public void testGetResource() { assertNotNull(mock.getResource(MockBundleTest.class.getPackage().getName().replace('.', '/') + "/MockBundleTest.class")); }
1,101,406
public void testGetResources() throws Exception { assertNotNull(mock.getResources(MockBundleTest.class.getPackage().getName().replace(".", "/"))); }
public void testGetResources() throws Exception { assertNotNull(mock.getResources(MockBundleTest.class.getPackage().getName().replace('.', '/'))); }
1,101,407
public void actionPerformed(ActionEvent e) { JFileChooser chooser = new JFileChooser(DODDLE.PROJECT_DIR); chooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY); int retval = chooser.showOpenDialog(DODDLE.rootPane); if (retval != JFileChooser.APPROVE_OPTION) { return; } openD...
public void actionPerformed(ActionEvent e) { JFileChooser chooser = new JFileChooser(DODDLE.PROJECT_DIR); chooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY); int retval = chooser.showOpenDialog(DODDLE.rootPane); if (retval != JFileChooser.APPROVE_OPTION) { return; } openD...
1,101,408
public void run() { try { DODDLE.STATUS_BAR.setLastMessage("プロジェクト復元完了"); DODDLE.STATUS_BAR.startTime(); DODDLE.STATUS_BAR.initNormal(17); DODDLE.STATUS_BAR.lock(); DODDLEProject project = new DODDL...
public void run() { try { DODDLE.STATUS_BAR.setLastMessage("プロジェクト復元完了"); DODDLE.STATUS_BAR.startTime(); DODDLE.STATUS_BAR.initNormal(17); DODDLE.STATUS_BAR.lock(); DODDLEProject project = new DODDL...
1,101,409
public static void main(final String args[]) { boolean failed = false; if (args.length == 0) { printUsage(); return; } ScriptsRunner runner = new ScriptsRunner(); runner.setProgressIndicator(new ConsoleProgressIndicator( "Scripts execution")); ...
public static void main(final String args[]) { boolean failed = false; if (args.length == 0) { printUsage(); return; } ScriptsRunner runner = new ScriptsRunner(); runner.setProgressIndicator(new ConsoleProgressIndicator( "Scripts execution")); ...
1,101,411
public static void main(final String args[]) { boolean failed = false; if (args.length == 0) { printUsage(); return; } ScriptsRunner runner = new ScriptsRunner(); runner.setProgressIndicator(new ConsoleProgressIndicator( "Scripts execution")); ...
public static void main(final String args[]) { boolean failed = false; if (args.length == 0) { printUsage(); return; } ScriptsRunner runner = new ScriptsRunner(); runner.setProgressIndicator(new ConsoleProgressIndicator( "Scripts execution")); ...
1,101,412
public static void main(final String args[]) { boolean failed = false; if (args.length == 0) { printUsage(); return; } ScriptsRunner runner = new ScriptsRunner(); runner.setProgressIndicator(new ConsoleProgressIndicator( "Scripts execution")); ...
public static void main(final String args[]) { boolean failed = false; if (args.length == 0) { printUsage(); return; } ScriptsRunner runner = new ScriptsRunner(); runner.setProgressIndicator(new ConsoleProgressIndicator( "Scripts execution")); ...
1,101,413
private static void printUsage() { System.out.println("Usage java " + ScriptsRunner.class.getName() + " <file 1>[ ... <file N>]"); }
private static void printUsage() { System.out.println("Usage java " + ScriptsRunner.class.getName() + " [-options] [<file 1> ... <file N>]"); System.out.println("where options include:"); System.out.println(" -h displays help "); System.out.println(" A ; separated list of directories,...
1,101,414
public boolean checkName( final String basePath, final String path, final NameScope scope ) { if ( scope == NameScope.CHILD ) { final int baseLen = basePath.length(); if ( !path.startsWith( basePath ) || ...
public boolean checkName( final String basePath, final String path, final NameScope scope ) { if ( scope == NameScope.CHILD ) { final int baseLen = basePath.length(); if ( !path.startsWith( basePath ) || ...
1,101,415
public boolean checkName( final String basePath, final String path, final NameScope scope ) { if ( scope == NameScope.CHILD ) { final int baseLen = basePath.length(); if ( !path.startsWith( basePath ) || ...
public boolean checkName( final String basePath, final String path, final NameScope scope ) { if ( scope == NameScope.CHILD ) { final int baseLen = basePath.length(); if ( !path.startsWith( basePath ) || ...
1,101,416
public void execute() throws BuildException { List<File> files = new ArrayList<File>(); if (filesets.isEmpty()) { //if no files - script.xml is a default name files.add(new File(getProject().getBaseDir(), "script.xml")); } else { for (FileSet fs : filesets) { ...
public void execute() throws BuildException { List<File> files = new ArrayList<File>(); if (filesets.isEmpty()) { //if no files - script.xml is a default name files.add(new File(getProject().getBaseDir(), "script.xml")); } else { for (FileSet fs : filesets) { ...
1,101,417
protected FileObject getBaseFolder() throws Exception { final String uri = System.getProperty( "test.smb.uri" ) + "/read-tests"; m_manager.addProvider( "smb", new SmbFileSystemProvider() ); return m_manager.resolveFile( uri ); }
protected FileObject getBaseFolder() throws Exception { final String uri = System.getProperty( "test.smb.uri" ) + "/read-tests"; m_manager.addProvider( "smb", new SmbFileSystemProvider() ); return m_manager.resolveFile( uri ); }
1,101,418
protected FileObject getWriteFolder() throws Exception { final String uri = System.getProperty( "test.smb.uri" ) + "/write-tests"; return m_manager.resolveFile( uri ); }
protected FileObject getWriteFolder() throws Exception { final String uri = System.getProperty( "test.smb.uri" ) + "/write-tests"; return getManager().resolveFile( uri ); }
1,101,419
private VFSClassLoader createClassLoader() throws FileSystemException { final VFSClassLoader loader = new VFSClassLoader( getReadFolder(), getManager() ); return loader; }
private VFSClassLoader createClassLoader() throws FileSystemException { final VFSClassLoader loader = new VFSClassLoader( getBaseFolder(), getManager() ); return loader; }
1,101,420
public void testLoadClass() throws Exception { final VFSClassLoader loader = createClassLoader(); final Class testClass = loader.loadClass( "code.ClassToLoad" ); final Package pack = testClass.getPackage(); assertEquals( "code", pack.getName() ); verifyPackage( getReadFolder(),...
public void testLoadClass() throws Exception { final VFSClassLoader loader = createClassLoader(); final Class testClass = loader.loadClass( "code.ClassToLoad" ); final Package pack = testClass.getPackage(); assertEquals( "code", pack.getName() ); verifyPackage( pack, false ); ...
1,101,421
public void testLoadResource() throws Exception { final VFSClassLoader loader = createClassLoader(); final URL resource = loader.getResource( "file1.txt" ); assertNotNull( resource ); final URLConnection urlCon = resource.openConnection(); assertSameURLContent( FILE1_CONTENT, u...
public void testLoadResource() throws Exception { final VFSClassLoader loader = createClassLoader(); final URL resource = loader.getResource( "read-tests/file1.txt" ); assertNotNull( resource ); final URLConnection urlCon = resource.openConnection(); assertSameURLContent( FILE1...
1,101,422
public void testSealing() throws Exception { final VFSClassLoader loader = createClassLoader(); final Class testClass = loader.loadClass( "code.sealed.AnotherClass" ); final Package pack = testClass.getPackage(); assertEquals( "code.sealed", pack.getName() ); verifyPackage( get...
public void testSealing() throws Exception { final VFSClassLoader loader = createClassLoader(); final Class testClass = loader.loadClass( "code.sealed.AnotherClass" ); final Package pack = testClass.getPackage(); assertEquals( "code.sealed", pack.getName() ); verifyPackage( pac...
1,101,423
private void verifyPackage( final FileObject baseFolder, final Package pack, boolean sealed ) throws FileSystemException { if ( baseFolder.getFileSystem().hasCapability( Capability.MANIFEST_ATTRIBUTES ) ) { assertEquals...
private void verifyPackage( final FileObject baseFolder, final Package pack, boolean sealed ) throws FileSystemException { if ( baseFolder.getFileSystem().hasCapability( Capability.MANIFEST_ATTRIBUTES ) ) { assertEquals...
1,101,424
private void verifyPackage( final FileObject baseFolder, final Package pack, boolean sealed ) throws FileSystemException { if ( baseFolder.getFileSystem().hasCapability( Capability.MANIFEST_ATTRIBUTES ) ) { assertEquals...
private void verifyPackage( final FileObject baseFolder, final Package pack, boolean sealed ) throws FileSystemException { if ( getBaseFolder().getFileSystem().hasCapability( Capability.MANIFEST_ATTRIBUTES ) ) { assertE...
1,101,425
public FileObject getBaseTestFolder( final FileSystemManager manager ) throws Exception { final FileObject baseFolder = config.getBaseTestFolder( manager ); // Create an empty file system, then link in read-tests and write-tests final FileSystem newFs = manager.createFileSystem( "vfs:" ).get...
public FileObject getBaseTestFolder( final FileSystemManager manager ) throws Exception { final FileObject baseFolder = config.getBaseTestFolder( manager ); // Create an empty file system, then link in read-tests and write-tests final FileSystem newFs = manager.createFileSystem( "vfs:" ).get...
1,101,426
protected void addFileSystem(final Comparable key, final FileSystem fs) throws FileSystemException { synchronized (fileSystems) { // Add to the cache addComponent(fs); FileSystemKey treeKey = new FileSystemKey(key, fs.getFileSystemOptions()); ((Abs...
protected void addFileSystem(final Comparable key, final FileSystem fs) throws FileSystemException { synchronized (fileSystems) { // Add to the cache addComponent(fs); FileSystemKey treeKey = new FileSystemKey(key, fs.getFileSystemOptions()); ((Abs...
1,101,427
public void closeFileSystem(final FileSystem filesystem) { AbstractFileSystem fs = (AbstractFileSystem) filesystem; synchronized (fileSystems) { fileSystems.remove(fs.getCacheKey()); } removeComponent(fileSystems); fs.close(); }
public void closeFileSystem(final FileSystem filesystem) { AbstractFileSystem fs = (AbstractFileSystem) filesystem; synchronized (fileSystems) { fileSystems.remove(fs.getCacheKey()); } removeComponent(fs); fs.close(); }
1,101,428
protected FileSystem findFileSystem(final Comparable key, final FileSystemOptions fileSystemProps) { synchronized (fileSystems) { FileSystemKey treeKey = new FileSystemKey(key, fileSystemProps); return (FileSystem) fileSystems.get(treeKey); } }
protected FileSystem findFileSystem(final Comparable key, final FileSystemOptions fileSystemProps) { synchronized (fileSystems) { return (FileSystem) fileSystems.get(treeKey); } }
1,101,429
public void freeUnusedResources() { synchronized (fileSystems) { Iterator iterFileSystems = fileSystems.values().iterator(); while (iterFileSystems.hasNext()) { AbstractFileSystem fs = (AbstractFileSystem) iterFileSystems.next(); if (fs...
public void freeUnusedResources() { synchronized (fileSystems) { Iterator iterFileSystems = fileSystems.values().iterator(); while (iterFileSystems.hasNext()) { AbstractFileSystem fs = (AbstractFileSystem) iterFileSystems.next(); if (fs...
1,101,430
public void freeUnusedResources() { synchronized (fileSystems) { Iterator iterFileSystems = fileSystems.values().iterator(); while (iterFileSystems.hasNext()) { AbstractFileSystem fs = (AbstractFileSystem) iterFileSystems.next(); if (fs...
public void freeUnusedResources() { synchronized (fileSystems) { Iterator iterFileSystems = fileSystems.values().iterator(); while (iterFileSystems.hasNext()) { AbstractFileSystem fs = (AbstractFileSystem) iterFileSystems.next(); if (fs...
1,101,431