id
stringlengths
7
14
test_class
dict
test_case
dict
focal_class
dict
focal_method
dict
repository
dict
79564911_411
{ "fields": [], "file": "storegate/src/test/java/ch/cyberduck/core/storegate/StoregateMoveFeatureTest.java", "identifier": "StoregateMoveFeatureTest", "interfaces": "", "superclass": "extends AbstractStoregateTest" }
{ "body": "@Test\n public void testMoveWithLock() throws Exception {\n final StoregateIdProvider nodeid = new StoregateIdProvider(session).withCache(cache);\n final Path room = new StoregateDirectoryFeature(session, nodeid).mkdir(\n new Path(String.format(\"/My files/%s\", new Alphanumeric...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final StoregateSession session;", "type": "StoregateSession", "var_name": "session" }, { "declarator": "fileid", "modifier": "private final", "original_string":...
{ "body": "@Override\n public Path move(final Path file, final Path renamed, final TransferStatus status, final Delete.Callback delete, final ConnectionCallback callback) throws BackgroundException {\n try {\n final StoregateApiClient client = session.getClient();\n final MoveFileReque...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_104
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3VersionedObjectListServiceTest.java", "identifier": "S3VersionedObjectListServiceTest", "interfaces": "", "superclass": "extends AbstractS3Test" }
{ "body": "@Test\n public void testListInvisibleCharacter() throws Exception {\n final Path container = new Path(\"versioning-test-us-east-1-cyberduck\", EnumSet.of(Path.Type.directory, Path.Type.volume));\n container.attributes().setRegion(\"us-east-1\");\n final Path placeholder = new S3Touc...
{ "fields": [ { "declarator": "log = Logger.getLogger(S3VersionedObjectListService.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3VersionedObjectListService.class);", "type": "Logger", "var_name": "log" }, ...
{ "body": "@Override\n public AttributedList<Path> list(final Path directory, final ListProgressListener listener) throws BackgroundException {\n final ThreadPool pool = ThreadPoolFactory.get(\"list\", concurrency);\n try {\n final String prefix = this.createPrefix(directory);\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_554
{ "fields": [], "file": "webdav/src/test/java/ch/cyberduck/core/dav/DAVSessionTest.java", "identifier": "DAVSessionTest", "interfaces": "", "superclass": "extends AbstractDAVTest" }
{ "body": "@Test\n public void testConnect() throws Exception {\n final Host host = new Host(new DAVSSLProtocol(), \"svn.cyberduck.io\");\n final DAVSession session = new DAVSession(host,\n new CertificateStoreX509TrustManager(new DisabledCertificateTrustCallback(), new DefaultTrustManager...
{ "fields": [ { "declarator": "log = Logger.getLogger(DAVSession.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(DAVSession.class);", "type": "Logger", "var_name": "log" }, { "declarator": "redirect\n ...
{ "body": "@Override\n public DAVClient connect(final Proxy proxy, final HostKeyCallback key, final LoginCallback prompt) throws BackgroundException {\n // Always inject new pool to builder on connect because the pool is shutdown on disconnect\n final HttpClientBuilder pool = builder.build(proxy, thi...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_807
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/PathRelativizerTest.java", "identifier": "PathRelativizerTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testRelativize() {\n assertEquals(\"a\", PathRelativizer.relativize(\"/\", \"/a\"));\n assertEquals(\"/b/path\", PathRelativizer.relativize(\"/a\", \"/b/path\"));\n assertEquals(\"path\", PathRelativizer.relativize(\"/a\", \"/a/path\"));\n assertEquals(\"a...
{ "fields": [], "file": "core/src/main/java/ch/cyberduck/core/PathRelativizer.java", "identifier": "PathRelativizer", "interfaces": "", "methods": [ { "class_method_signature": "PathRelativizer.PathRelativizer()", "constructor": true, "full_signature": "private PathRelativizer()", ...
{ "body": "public static String relativize(String root, final String path) {\n if(StringUtils.isBlank(root)) {\n return path;\n }\n if(!StringUtils.equals(root, String.valueOf(Path.DELIMITER))) {\n root = root + Path.DELIMITER;\n }\n if(StringUtils.contains(pat...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1452
{ "fields": [], "file": "cli/src/test/java/ch/cyberduck/cli/CommandLineUriParserTest.java", "identifier": "CommandLineUriParserTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testCustomProvider() throws Exception {\n final CommandLineParser parser = new PosixParser();\n final CommandLine input = parser.parse(new Options(), new String[]{});\n final ProtocolFactory factory = new ProtocolFactory(new LinkedHashSet<>(Collections.singletonL...
{ "fields": [ { "declarator": "log = Logger.getLogger(CommandLineUriParser.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(CommandLineUriParser.class);", "type": "Logger", "var_name": "log" }, { "declar...
{ "body": "public Host parse(final String uri) throws HostParserException {\n final Host host = new HostParser(factory).get(uri);\n if(input.hasOption(TerminalOptionsBuilder.Params.region.name())) {\n host.setRegion(input.getOptionValue(TerminalOptionsBuilder.Params.region.name()));\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1002
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/transfer/upload/ResumeFilterTest.java", "identifier": "ResumeFilterTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testPrepare() throws Exception {\n final ResumeFilter f = new ResumeFilter(new DisabledUploadSymlinkResolver(), new NullSession(new Host(new TestProtocol())) {\n @Override\n public AttributedList<Path> list(final Path file, final ListProgressListener list...
{ "fields": [ { "declarator": "log = Logger.getLogger(ResumeFilter.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(ResumeFilter.class);", "type": "Logger", "var_name": "log" }, { "declarator": "upload",...
{ "body": "@Override\n public TransferStatus prepare(final Path file, final Local local, final TransferStatus parent, final ProgressListener progress) throws BackgroundException {\n final TransferStatus status = super.prepare(file, local, parent, progress);\n if(file.isFile()) {\n if(paren...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_780
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/ui/browser/UploadTargetFinderTest.java", "identifier": "UploadTargetFinderTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testFindContainerSelected() {\n assertEquals(new Path(\"/container\", EnumSet.of(Path.Type.directory, Path.Type.volume)),\n new UploadTargetFinder(new Path(\"/\", EnumSet.of(Path.Type.directory)))\n .find(new Path(\"/container\", EnumSet.o...
{ "fields": [ { "declarator": "workdir", "modifier": "private final", "original_string": "private final Path workdir;", "type": "Path", "var_name": "workdir" } ], "file": "core/src/main/java/ch/cyberduck/ui/browser/UploadTargetFinder.java", "identifier": "UploadTargetFinder...
{ "body": "public Path find(final Path selected) {\n if(null == selected) {\n return workdir;\n }\n if(selected.getType().contains(Path.Type.volume)) {\n return selected;\n }\n return selected.getParent();\n }", "class_method_signature": "UploadTargetFinde...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_295
{ "fields": [], "file": "azure/src/test/java/ch/cyberduck/core/azure/AzureDeleteFeatureTest.java", "identifier": "AzureDeleteFeatureTest", "interfaces": "", "superclass": "" }
{ "body": "@Test(expected = NotfoundException.class)\n public void testDeleteNotFoundKey() throws Exception {\n final Host host = new Host(new AzureProtocol(), \"kahy9boj3eib.blob.core.windows.net\", new Credentials(\n System.getProperties().getProperty(\"azure.account\"), System.getPropertie...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final AzureSession session;", "type": "AzureSession", "var_name": "session" }, { "declarator": "context", "modifier": "private final", "original_string": "priva...
{ "body": "@Override\n public void delete(final Map<Path, TransferStatus> files, final PasswordCallback prompt, final Callback callback) throws BackgroundException {\n final List<Path> containers = new ArrayList<Path>();\n for(Path file : files.keySet()) {\n if(containerService.isContainer...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1393
{ "fields": [], "file": "openstack/src/test/java/ch/cyberduck/core/openstack/SwiftAuthenticationServiceTest.java", "identifier": "SwiftAuthenticationServiceTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testDefault() throws Exception {\n final SwiftAuthenticationService s = new SwiftAuthenticationService();\n final SwiftProtocol protocol = new SwiftProtocol() {\n @Override\n public String getContext() {\n return \"/v1.0\";\n ...
{ "fields": [ { "declarator": "log = Logger.getLogger(SwiftAuthenticationService.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SwiftAuthenticationService.class);", "type": "Logger", "var_name": "log" } ], "...
{ "body": "public Set<? extends AuthenticationRequest> getRequest(final Host bookmark, final LoginCallback prompt)\n throws LoginCanceledException {\n final StringBuilder url = new StringBuilder();\n url.append(bookmark.getProtocol().getScheme().toString()).append(\"://\");\n url.appen...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1239
{ "fields": [], "file": "backblaze/src/test/java/ch/cyberduck/core/b2/B2LargeCopyFeatureTest.java", "identifier": "B2LargeCopyFeatureTest", "interfaces": "", "superclass": "extends AbstractB2Test" }
{ "body": "@Test\n public void testCopyToExistingFile() throws Exception {\n final B2FileidProvider fileid = new B2FileidProvider(session).withCache(cache);\n final Path container = new Path(\"test-cyberduck\", EnumSet.of(Path.Type.directory, Path.Type.volume));\n final Path folder = new B2Dir...
{ "fields": [ { "declarator": "log = Logger.getLogger(B2LargeCopyFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(B2LargeCopyFeature.class);", "type": "Logger", "var_name": "log" }, { "declarator...
{ "body": "@Override\n public Path copy(final Path source, final Path target, final TransferStatus status, final ConnectionCallback callback) throws BackgroundException {\n final ThreadPool pool = ThreadPoolFactory.get(\"largeupload\", concurrency);\n try {\n final Map<String, String> file...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_446
{ "fields": [], "file": "osx/src/test/java/ch/cyberduck/ui/cocoa/UserDefaultsDateFormatterTest.java", "identifier": "UserDefaultsDateFormatterTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testGetLongFormat() {\n final UserDateFormatter f = new UserDefaultsDateFormatter(TimeZone.getDefault().getID());\n assertNotNull(f.getLongFormat(System.currentTimeMillis(), false));\n assertNotNull(f.getLongFormat(System.currentTimeMillis(), true));\n }", "...
{ "fields": [ { "declarator": "locale = NSLocale.currentLocale()", "modifier": "private static final", "original_string": "private static final NSLocale locale = NSLocale.currentLocale();", "type": "NSLocale", "var_name": "locale" }, { "declarator": "timezone", "m...
{ "body": "@Override\n public String getLongFormat(final long milliseconds, boolean natural) {\n synchronized(longDateFormatter) {\n if(-1 == milliseconds) {\n return LocaleFactory.localizedString(\"Unknown\");\n }\n longDateFormatter.setTimeZone(NSTimeZone.ti...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_62
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3MetadataFeatureTest.java", "identifier": "S3MetadataFeatureTest", "interfaces": "", "superclass": "extends AbstractS3Test" }
{ "body": "@Test\n public void testGetMetadataBucket() throws Exception {\n final Path container = new Path(\"test-us-east-1-cyberduck\", EnumSet.of(Path.Type.volume));\n final Map<String, String> metadata = new S3MetadataFeature(session, new S3AccessControlListFeature(session)).getMetadata(container...
{ "fields": [ { "declarator": "log = Logger.getLogger(S3MetadataFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3MetadataFeature.class);", "type": "Logger", "var_name": "log" }, { "declarator":...
{ "body": "@Override\n public Map<String, String> getMetadata(final Path file) throws BackgroundException {\n return new S3AttributesFinderFeature(session).find(file).getMetadata();\n }", "class_method_signature": "S3MetadataFeature.getMetadata(final Path file)", "constructor": false, "full_signatu...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1110
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/local/DefaultLocalTouchFeatureTest.java", "identifier": "DefaultLocalTouchFeatureTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testTouch() throws Exception {\n Local parent = new Local(System.getProperty(\"java.io.tmpdir\"), new AlphanumericRandomStringService().random());\n Local l = new Local(parent, UUID.randomUUID().toString());\n final DefaultLocalTouchFeature f = new DefaultLocalTo...
{ "fields": [ { "declarator": "log = Logger.getLogger(DefaultLocalTouchFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(DefaultLocalTouchFeature.class);", "type": "Logger", "var_name": "log" } ], "file...
{ "body": "@Override\n public void touch(final Local file) throws AccessDeniedException {\n try {\n try {\n Files.createFile(Paths.get(file.getAbsolute()));\n }\n catch(NoSuchFileException e) {\n final Local parent = file.getParent();\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_915
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/worker/ReadMetadataWorkerTest.java", "identifier": "ReadMetadataWorkerTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testEmpty() throws Exception {\n final List<Path> files = new ArrayList<Path>();\n ReadMetadataWorker worker = new ReadMetadataWorker(files) {\n @Override\n public void cleanup(final Map<String, String> result) {\n fail();\n ...
{ "fields": [ { "declarator": "log = Logger.getLogger(ReadMetadataWorker.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(ReadMetadataWorker.class);", "type": "Logger", "var_name": "log" }, { "declarator...
{ "body": "@Override\n public Map<String, String> run(final Session<?> session) throws BackgroundException {\n final Metadata feature = session.getFeature(Metadata.class);\n if(log.isDebugEnabled()) {\n log.debug(String.format(\"Run with feature %s\", feature));\n }\n // Map ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1055
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/transfer/normalizer/CopyRootPathsNormalizerTest.java", "identifier": "CopyRootPathsNormalizerTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testNormalize2() {\n CopyRootPathsNormalizer normalizer = new CopyRootPathsNormalizer();\n final HashMap<Path, Path> files = new HashMap<Path, Path>();\n files.put(new Path(\"/p/child\", EnumSet.of(Path.Type.directory)), new Path(\"/d/child\", EnumSet.of(Path.Typ...
{ "fields": [ { "declarator": "log = Logger.getLogger(CopyRootPathsNormalizer.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(CopyRootPathsNormalizer.class);", "type": "Logger", "var_name": "log" } ], "file":...
{ "body": "@Override\n public Map<Path, Path> normalize(final Map<Path, Path> files) {\n final Map<Path, Path> normalized = new HashMap<Path, Path>();\n Iterator<Path> sourcesIter = files.keySet().iterator();\n Iterator<Path> destinationsIter = files.values().iterator();\n while(sources...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_850
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/io/DisabledChecksumComputeTest.java", "identifier": "DisabledChecksumComputeTest", "interfaces": "", "superclass": "" }
{ "body": "@Test(expected = IOException.class)\n public void compute() throws Exception {\n final NullInputStream in = new NullInputStream(0L);\n new DisabledChecksumCompute().compute(in, new TransferStatus());\n assertEquals(-1, in.read());\n in.read();\n }", "class_method_signatu...
{ "fields": [], "file": "core/src/main/java/ch/cyberduck/core/io/DisabledChecksumCompute.java", "identifier": "DisabledChecksumCompute", "interfaces": "implements ChecksumCompute", "methods": [ { "class_method_signature": "DisabledChecksumCompute.compute(final InputStream in, final TransferStatus st...
{ "body": "@Override\n public Checksum compute(final InputStream in, final TransferStatus status) {\n IOUtils.closeQuietly(in);\n return Checksum.NONE;\n }", "class_method_signature": "DisabledChecksumCompute.compute(final InputStream in, final TransferStatus status)", "constructor": false, ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1405
{ "fields": [], "file": "openstack/src/test/java/ch/cyberduck/core/openstack/SwiftAttributesFinderFeatureTest.java", "identifier": "SwiftAttributesFinderFeatureTest", "interfaces": "", "superclass": "extends AbstractSwiftTest" }
{ "body": "@Test\n public void testFindPlaceholder() throws Exception {\n final Path container = new Path(\"test.cyberduck.ch\", EnumSet.of(Path.Type.directory, Path.Type.volume));\n container.attributes().setRegion(\"IAD\");\n final String name = UUID.randomUUID().toString();\n final P...
{ "fields": [ { "declarator": "log = Logger.getLogger(SwiftAttributesFinderFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SwiftAttributesFinderFeature.class);", "type": "Logger", "var_name": "log" }, ...
{ "body": "@Override\n public PathAttributes find(final Path file) throws BackgroundException {\n if(file.isRoot()) {\n return PathAttributes.EMPTY;\n }\n final Region region = regionService.lookup(file);\n try {\n if(containerService.isContainer(file)) {\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_503
{ "fields": [], "file": "dracoon/src/test/java/ch/cyberduck/core/sds/triplecrypt/TripleCryptConverterTest.java", "identifier": "TripleCryptConverterTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testFileKey() throws Exception {\n final JSON json = new JSON();\n final FileKey fileKey = TripleCryptConverter.toSwaggerFileKey(Crypto.generateFileKey());\n assertNotNull(fileKey.getIv());\n assertNotNull(fileKey.getKey());\n assertNull(fileKey.get...
{ "fields": [], "file": "dracoon/src/main/java/ch/cyberduck/core/sds/triplecrypt/TripleCryptConverter.java", "identifier": "TripleCryptConverter", "interfaces": "", "methods": [ { "class_method_signature": "TripleCryptConverter.toSwaggerFileKey(final EncryptedFileKey k)", "constructor": false,...
{ "body": "public static FileKey toSwaggerFileKey(final EncryptedFileKey k) {\n return new FileKey().key(k.getKey()).iv(k.getIv()).tag(k.getTag()).version(k.getVersion());\n }", "class_method_signature": "TripleCryptConverter.toSwaggerFileKey(final EncryptedFileKey k)", "constructor": false, "full_sig...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_153
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3ObjectListServiceTest.java", "identifier": "S3ObjectListServiceTest", "interfaces": "", "superclass": "extends AbstractS3Test" }
{ "body": "@Test\n public void testListPlaceholderTilde() throws Exception {\n final Path container = new Path(\"test-us-east-1-cyberduck\", EnumSet.of(Path.Type.directory, Path.Type.volume));\n container.attributes().setRegion(\"us-east-1\");\n final Path placeholder = new S3DirectoryFeature(...
{ "fields": [ { "declarator": "log = Logger.getLogger(S3ObjectListService.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3ObjectListService.class);", "type": "Logger", "var_name": "log" }, { "declarat...
{ "body": "@Override\n public AttributedList<Path> list(final Path directory, final ListProgressListener listener) throws BackgroundException {\n return this.list(directory, listener, String.valueOf(Path.DELIMITER));\n }", "class_method_signature": "S3ObjectListService.list(final Path directory, final ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_796
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/ui/comparator/TimestampComparatorTest.java", "identifier": "TimestampComparatorTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testCompareFirst() {\n assertEquals(0, new TimestampComparator(true).compareFirst(new Path(\"/a\", EnumSet.of(Path.Type.file)), new Path(\"/b\", EnumSet.of(Path.Type.file))));\n final Path p1 = new Path(\"/a\", EnumSet.of(Path.Type.file));\n p1.attributes().setMo...
{ "fields": [ { "declarator": "serialVersionUID = 2242337528465570314L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = 2242337528465570314L;", "type": "long", "var_name": "serialVersionUID" } ], "file": "core/src/main/jav...
{ "body": "@Override\n protected int compareFirst(final Path p1, final Path p2) {\n final long d1 = p1.attributes().getModificationDate();\n final long d2 = p2.attributes().getModificationDate();\n if(d1 == d2) {\n return 0;\n }\n if(ascending) {\n return d1...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1385
{ "fields": [], "file": "openstack/src/test/java/ch/cyberduck/core/openstack/SwiftDistributionPurgeFeatureTest.java", "identifier": "SwiftDistributionPurgeFeatureTest", "interfaces": "", "superclass": "extends AbstractSwiftTest" }
{ "body": "@Test\n public void testInvalidateFile() throws Exception {\n final SwiftDistributionPurgeFeature feature = new SwiftDistributionPurgeFeature(session);\n final Path container = new Path(\"test.cyberduck.ch\", EnumSet.of(Path.Type.volume, Path.Type.directory));\n container.attributes...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final SwiftSession session;", "type": "SwiftSession", "var_name": "session" }, { "declarator": "containerService\n = new PathContainerService()", "modifier...
{ "body": "@Override\n public void invalidate(final Path container, final Distribution.Method method, final List<Path> files, final LoginCallback prompt) throws BackgroundException {\n try {\n for(Path file : files) {\n if(containerService.isContainer(file)) {\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_283
{ "fields": [], "file": "ftp/src/test/java/ch/cyberduck/core/ftp/FTPMFMTTimestampFeatureTest.java", "identifier": "FTPMFMTTimestampFeatureTest", "interfaces": "", "superclass": "extends AbstractFTPTest" }
{ "body": "@Test\n public void testSetTimestamp() throws Exception {\n final Path home = new FTPWorkdirService(session).find();\n final long modified = System.currentTimeMillis();\n final Path test = new Path(new FTPWorkdirService(session).find(), UUID.randomUUID().toString(), EnumSet.of(Path....
{ "fields": [ { "declarator": "log = Logger.getLogger(FTPMFMTTimestampFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(FTPMFMTTimestampFeature.class);", "type": "Logger", "var_name": "log" }, { "...
{ "body": "@Override\n public void setTimestamp(final Path file, final TransferStatus status) throws BackgroundException {\n if(failure != null) {\n if(log.isDebugEnabled()) {\n log.debug(String.format(\"Skip setting timestamp for %s due to previous failure %s\", file, failure.getM...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_779
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/ui/browser/UploadTargetFinderTest.java", "identifier": "UploadTargetFinderTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testFind() {\n assertEquals(new Path(\"/\", EnumSet.of(Path.Type.directory, Path.Type.volume)),\n new UploadTargetFinder(new Path(\"/\", EnumSet.of(Path.Type.directory, Path.Type.volume))).find(null));\n assertEquals(new Path(\"/\", EnumSet.of(Path.Type.d...
{ "fields": [ { "declarator": "workdir", "modifier": "private final", "original_string": "private final Path workdir;", "type": "Path", "var_name": "workdir" } ], "file": "core/src/main/java/ch/cyberduck/ui/browser/UploadTargetFinder.java", "identifier": "UploadTargetFinder...
{ "body": "public Path find(final Path selected) {\n if(null == selected) {\n return workdir;\n }\n if(selected.getType().contains(Path.Type.volume)) {\n return selected;\n }\n return selected.getParent();\n }", "class_method_signature": "UploadTargetFinde...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_329
{ "fields": [], "file": "nio/src/test/java/ch/cyberduck/core/nio/LocalMoveFeatureTest.java", "identifier": "LocalMoveFeatureTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testRenameCaseOnly() throws Exception {\n final LocalSession session = new LocalSession(new Host(new LocalProtocol(), new LocalProtocol().getDefaultHostname()));\n session.open(Proxy.DIRECT, new DisabledHostKeyCallback(), new DisabledLoginCallback());\n session.l...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final LocalSession session;", "type": "LocalSession", "var_name": "session" } ], "file": "nio/src/main/java/ch/cyberduck/core/nio/LocalMoveFeature.java", "identifier": "LocalMo...
{ "body": "@Override\n public Path move(final Path file, final Path renamed, final TransferStatus status, final Delete.Callback callback, final ConnectionCallback connectionCallback) throws BackgroundException {\n if(!new LocalFindFeature(session).find(file)) {\n throw new NotfoundException(file....
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_903
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/StringAppenderTest.java", "identifier": "StringAppenderTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testAppend() {\n assertEquals(\"Verification Code.\", new StringAppender().append(\"Verification Code:\").toString());\n assertEquals(\"Message.\", new StringAppender().append(\"Message\").toString());\n assertEquals(\"Message.\", new StringAppender().append(\"Me...
{ "fields": [ { "declarator": "buffer", "modifier": "private final", "original_string": "private final StringBuilder buffer;", "type": "StringBuilder", "var_name": "buffer" }, { "declarator": "suffix", "modifier": "private final", "original_string": "private...
{ "body": "public StringAppender append(final String message) {\n if(StringUtils.isBlank(message)) {\n return this;\n }\n if(buffer.length() > 0) {\n buffer.append(\" \");\n }\n buffer.append(StringUtils.trim(message));\n if(buffer.charAt(buffer.length()...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1106
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/local/DefaultTemporaryFileServiceTest.java", "identifier": "DefaultTemporaryFileServiceTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testCreateContainer() {\n final String temp = StringUtils.removeEnd(System.getProperty(\"java.io.tmpdir\"), File.separator);\n final String s = System.getProperty(\"file.separator\");\n final Path file = new Path(\"/container\", EnumSet.of(Path.Type.directory));\...
{ "fields": [ { "declarator": "delimiter\n = PreferencesFactory.get().getProperty(\"local.delimiter\")", "modifier": "private final", "original_string": "private final String delimiter\n = PreferencesFactory.get().getProperty(\"local.delimiter\");", "type": "String", "v...
{ "body": "@Override\n public Local create(final Path file) {\n return this.create(new UUIDRandomStringService().random(), file);\n }", "class_method_signature": "DefaultTemporaryFileService.create(final Path file)", "constructor": false, "full_signature": "@Override public Local create(final Path ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_74
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3PresignedUrlProviderTest.java", "identifier": "S3PresignedUrlProviderTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testCreateEuCentral() throws Exception {\n final Calendar expiry = Calendar.getInstance(TimeZone.getTimeZone(\"UTC\"));\n expiry.add(Calendar.MILLISECOND, (int) TimeUnit.DAYS.toMillis(7));\n final String url = new S3PresignedUrlProvider().create(new Host(new S3Pr...
{ "fields": [], "file": "s3/src/main/java/ch/cyberduck/core/s3/S3PresignedUrlProvider.java", "identifier": "S3PresignedUrlProvider", "interfaces": "", "methods": [ { "class_method_signature": "S3PresignedUrlProvider.create(final Host host, final String user, final String secret,\n ...
{ "body": "public String create(final Host host, final String user, final String secret,\n final String bucket, String region, final String key,\n final String method, final long expiry) {\n final S3Protocol.AuthenticationHeaderSignatureVersion signature;\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_450
{ "fields": [], "file": "dracoon/src/test/java/ch/cyberduck/core/sds/SDSMultipartWriteFeatureTest.java", "identifier": "SDSMultipartWriteFeatureTest", "interfaces": "", "superclass": "extends AbstractSDSTest" }
{ "body": "@Test(expected = InteroperabilityException.class)\n public void testWriteRoot() throws Exception {\n final SDSNodeIdProvider nodeid = new SDSNodeIdProvider(session).withCache(cache);\n final Path test = new Path(UUID.randomUUID().toString(), EnumSet.of(Path.Type.file));\n final Tran...
{ "fields": [ { "declarator": "log = Logger.getLogger(SDSMultipartWriteFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SDSMultipartWriteFeature.class);", "type": "Logger", "var_name": "log" }, { ...
{ "body": "@Override\n public HttpResponseOutputStream<VersionId> write(final Path file, final TransferStatus status, final ConnectionCallback callback) throws BackgroundException {\n final String uploadToken = upload.start(file, status);\n final MultipartUploadTokenOutputStream proxy = new Multipart...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_145
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3ObjectListServiceTest.java", "identifier": "S3ObjectListServiceTest", "interfaces": "", "superclass": "extends AbstractS3Test" }
{ "body": "@Test(expected = NotfoundException.class)\n public void testListNotFoundFolder() throws Exception {\n final Path container = new Path(\"test-us-east-1-cyberduck\", EnumSet.of(Path.Type.volume));\n new S3ObjectListService(session).list(new Path(container, \"notfound\", EnumSet.of(Path.Type....
{ "fields": [ { "declarator": "log = Logger.getLogger(S3ObjectListService.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3ObjectListService.class);", "type": "Logger", "var_name": "log" }, { "declarat...
{ "body": "@Override\n public AttributedList<Path> list(final Path directory, final ListProgressListener listener) throws BackgroundException {\n return this.list(directory, listener, String.valueOf(Path.DELIMITER));\n }", "class_method_signature": "S3ObjectListService.list(final Path directory, final ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_515
{ "fields": [], "file": "dracoon/src/test/java/ch/cyberduck/core/sds/SDSVersioningFeatureTest.java", "identifier": "SDSVersioningFeatureTest", "interfaces": "", "superclass": "extends AbstractSDSTest" }
{ "body": "@Test\n public void testRevert() throws Exception {\n final SDSNodeIdProvider nodeid = new SDSNodeIdProvider(session).withCache(cache);\n final Path room = new SDSDirectoryFeature(session, nodeid).mkdir(\n new Path(new AlphanumericRandomStringService().random(), EnumSet.of(Path....
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final SDSSession session;", "type": "SDSSession", "var_name": "session" }, { "declarator": "nodeid", "modifier": "private final", "original_string": "private fi...
{ "body": "@Override\n public void revert(final Path file) throws BackgroundException {\n try {\n new NodesApi(session.getClient()).restoreNodes(\n new RestoreDeletedNodesRequest()\n .resolutionStrategy(RestoreDeletedNodesRequest.ResolutionStrategyEnum.OVERWRITE)...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1413
{ "fields": [], "file": "openstack/src/test/java/ch/cyberduck/core/openstack/SwiftDeleteFeatureTest.java", "identifier": "SwiftDeleteFeatureTest", "interfaces": "", "superclass": "extends AbstractSwiftTest" }
{ "body": "@Test(expected = NotfoundException.class)\n public void testDeleteNotFoundKey() throws Exception {\n final Path container = new Path(\"test.cyberduck.ch\", EnumSet.of(Path.Type.directory, Path.Type.volume));\n container.attributes().setRegion(\"IAD\");\n final Path test = new Path(c...
{ "fields": [ { "declarator": "log = Logger.getLogger(SwiftDeleteFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SwiftDeleteFeature.class);", "type": "Logger", "var_name": "log" }, { "declarator...
{ "body": "@Override\n public void delete(final Map<Path, TransferStatus> files, final PasswordCallback prompt, final Callback callback) throws BackgroundException {\n this.delete(files, prompt, callback, true);\n }", "class_method_signature": "SwiftDeleteFeature.delete(final Map<Path, TransferStatus> ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_846
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/io/MD5ChecksumComputeTest.java", "identifier": "MD5ChecksumComputeTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testComputeEmptyString() throws Exception {\n assertEquals(\"d41d8cd98f00b204e9800998ecf8427e\",\n new MD5ChecksumCompute().compute(IOUtils.toInputStream(\"\", Charset.defaultCharset()), new TransferStatus()).hash);\n assertEquals(\"d41d8cd98f00b204e9800998ec...
{ "fields": [], "file": "core/src/main/java/ch/cyberduck/core/io/MD5ChecksumCompute.java", "identifier": "MD5ChecksumCompute", "interfaces": "", "methods": [ { "class_method_signature": "MD5ChecksumCompute.compute(final InputStream in, final TransferStatus status)", "constructor": false, ...
{ "body": "@Override\n public Checksum compute(final InputStream in, final TransferStatus status) throws ChecksumException {\n return new Checksum(HashAlgorithm.md5, Hex.encodeHexString(this.digest(\"MD5\",\n this.normalize(in, status))));\n }", "class_method_signature": "MD5ChecksumCompute....
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1043
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/transfer/CopyTransferTest.java", "identifier": "CopyTransferTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testActionPromptCancel() throws Exception {\n final Path test = new Path(\"t\", EnumSet.of(Path.Type.file));\n final Host target = new Host(new TestProtocol(), \"t\");\n CopyTransfer t = new CopyTransfer(target,\n target,\n Collectio...
{ "fields": [ { "declarator": "log = Logger.getLogger(CopyTransfer.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(CopyTransfer.class);", "type": "Logger", "var_name": "log" }, { "declarator": "filter =...
{ "body": "@Override\n public TransferAction action(final Session<?> source, final Session<?> destination, boolean resumeRequested, boolean reloadRequested,\n final TransferPrompt prompt, final ListProgressListener listener) throws BackgroundException {\n if(log.isDebugEnable...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1297
{ "fields": [], "file": "ssh/src/test/java/ch/cyberduck/core/sftp/SFTPMoveFeatureTest.java", "identifier": "SFTPMoveFeatureTest", "interfaces": "", "superclass": "extends AbstractSFTPTest" }
{ "body": "@Test\n public void testMove() throws Exception {\n final Path workdir = new SFTPHomeDirectoryService(session).find();\n final Path test = new SFTPTouchFeature(session).touch(new Path(workdir, UUID.randomUUID().toString(), EnumSet.of(Path.Type.file)), new TransferStatus());\n assert...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final SFTPSession session;", "type": "SFTPSession", "var_name": "session" }, { "declarator": "delete", "modifier": "private", "original_string": "private Delete...
{ "body": "@Override\n public Path move(final Path file, final Path renamed, final TransferStatus status, final Delete.Callback callback, final ConnectionCallback connectionCallback) throws BackgroundException {\n try {\n if(status.isExists()) {\n delete.delete(Collections.singleto...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_391
{ "fields": [], "file": "googledrive/src/test/java/ch/cyberduck/core/googledrive/DriveTouchFeatureTest.java", "identifier": "DriveTouchFeatureTest", "interfaces": "", "superclass": "extends AbstractDriveTest" }
{ "body": "@Test\n public void testTouch() throws Exception {\n final DriveFileidProvider fileid = new DriveFileidProvider(session).withCache(cache);\n final Path test = new DriveTouchFeature(session, fileid).touch(\n new Path(DriveHomeFinderService.MYDRIVE_FOLDER, UUID.randomUUID().toStri...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final DriveSession session;", "type": "DriveSession", "var_name": "session" }, { "declarator": "fileid", "modifier": "private final", "original_string": "privat...
{ "body": "@Override\n public Path touch(final Path file, final TransferStatus status) throws BackgroundException {\n try {\n final Drive.Files.Create insert = session.getClient().files().create(new File()\n .setName(file.getName())\n .setMimeType(status.getMime())\n...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_684
{ "fields": [], "file": "core/dylib/src/test/java/ch/cyberduck/core/resources/NSImageIconCacheTest.java", "identifier": "NSImageIconCacheTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testDocumentIconNoExtension() {\n final NSImage icon = new NSImageIconCache().documentIcon(\"\", 64);\n assertNotNull(icon);\n assertTrue(icon.isValid());\n assertFalse(icon.isTemplate());\n assertEquals(64, icon.size().width.intValue());\n a...
{ "fields": [ { "declarator": "log = Logger.getLogger(NSImageIconCache.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(NSImageIconCache.class);", "type": "Logger", "var_name": "log" }, { "declarator": "...
{ "body": "@Override\n public NSImage documentIcon(final String extension, final Integer size) {\n NSImage image = this.load(extension, size);\n if(null == image) {\n return this.cache(extension,\n this.convert(extension, NSWorkspace.sharedWorkspace().iconForFileType(extensi...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1278
{ "fields": [], "file": "ssh/src/test/java/ch/cyberduck/core/sftp/SFTPDirectoryFeatureTest.java", "identifier": "SFTPDirectoryFeatureTest", "interfaces": "", "superclass": "extends AbstractSFTPTest" }
{ "body": "@Test\n public void testMakeDirectory() throws Exception {\n final Path test = new Path(new SFTPHomeDirectoryService(session).find(), UUID.randomUUID().toString(), EnumSet.of(Path.Type.directory));\n new SFTPDirectoryFeature(session).mkdir(test, null, new TransferStatus());\n assert...
{ "fields": [ { "declarator": "preferences = PreferencesFactory.get()", "modifier": "private final", "original_string": "private final Preferences preferences = PreferencesFactory.get();", "type": "Preferences", "var_name": "preferences" }, { "declarator": "session", ...
{ "body": "@Override\n public Path mkdir(final Path folder, final String region, final TransferStatus status) throws BackgroundException {\n try {\n final FileAttributes attrs;\n if(Permission.EMPTY != status.getPermission()) {\n attrs = new FileAttributes.Builder().with...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_407
{ "fields": [], "file": "storegate/src/test/java/ch/cyberduck/core/storegate/StoregateTimestampFeatureTest.java", "identifier": "StoregateTimestampFeatureTest", "interfaces": "", "superclass": "extends AbstractStoregateTest" }
{ "body": "@Test\n public void testSetTimestamp() throws Exception {\n final StoregateIdProvider nodeid = new StoregateIdProvider(session).withCache(cache);\n final Path room = new StoregateDirectoryFeature(session, nodeid).mkdir(new Path(\n String.format(\"/My files/%s\", new Alphanumeric...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final StoregateSession session;", "type": "StoregateSession", "var_name": "session" }, { "declarator": "fileid", "modifier": "private final", "original_string":...
{ "body": "@Override\n public void setTimestamp(final Path file, final TransferStatus status) throws BackgroundException {\n try {\n final FilesApi files = new FilesApi(session.getClient());\n files.filesUpdateFile(fileid.getFileid(file, new DisabledListProgressListener()),\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_23
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3UrlProviderTest.java", "identifier": "S3UrlProviderTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testPlaceholder() {\n final S3Session session = new S3Session(new Host(new S3Protocol(), new S3Protocol().getDefaultHostname(), new Credentials(\n System.getProperties().getProperty(\"s3.key\"), null\n )));\n assertTrue(\n new S3UrlProvider(...
{ "fields": [ { "declarator": "log = Logger.getLogger(S3UrlProvider.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3UrlProvider.class);", "type": "Logger", "var_name": "log" }, { "declarator": "contai...
{ "body": "@Override\n public DescriptiveUrlBag toUrl(final Path file) {\n final DescriptiveUrlBag list = new DescriptiveUrlBag();\n if(file.isFile()) {\n // Publicly accessible URL of given object\n list.add(this.toUrl(file, session.getHost().getProtocol().getScheme(), session....
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1151
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/ProtocolFactoryTest.java", "identifier": "ProtocolFactoryTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testGetProtocols() {\n final TestProtocol defaultProtocol = new TestProtocol(Scheme.ftp);\n final TestProtocol providerProtocol = new TestProtocol(Scheme.ftp) {\n @Override\n public String getProvider() {\n return \"c\";\n ...
{ "fields": [ { "declarator": "log = Logger.getLogger(ProtocolFactory.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(ProtocolFactory.class);", "type": "Logger", "var_name": "log" }, { "declarator": "gl...
{ "body": "public List<Protocol> find() {\n return this.find(Protocol::isEnabled);\n }", "class_method_signature": "ProtocolFactory.find()", "constructor": false, "full_signature": "public List<Protocol> find()", "identifier": "find", "invocations": [ "find" ], "modifiers": "public", "pa...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1501
{ "fields": [], "file": "dropbox/src/test/java/ch/cyberduck/core/dropbox/DropboxPathContainerServiceTest.java", "identifier": "DropboxPathContainerServiceTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testNamespace() {\n final DropboxPathContainerService s = new DropboxPathContainerService();\n final Host host = new Host(new DropboxProtocol());\n assertEquals(PathRoot.namespaceId(\"r\"), s.getNamespace(new Path(\"/\", EnumSet.of(Path.Type.directory, Path.Type....
{ "fields": [ { "declarator": "useNamespace = false", "modifier": "private", "original_string": "private boolean useNamespace = false;", "type": "boolean", "var_name": "useNamespace" } ], "file": "dropbox/src/main/java/ch/cyberduck/core/dropbox/DropboxPathContainerService.jav...
{ "body": "protected PathRoot getNamespace(final Path file) {\n if(PreferencesFactory.get().getBoolean(\"dropbox.business.enable\")) {\n final Path container = this.getContainer(file);\n if(StringUtils.isNotBlank(container.attributes().getVersionId())) {\n // List relative ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_954
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/ssl/CustomTrustSSLProtocolSocketFactoryTest.java", "identifier": "CustomTrustSSLProtocolSocketFactoryTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testGetSSLContext() {\n assertNotNull(new CustomTrustSSLProtocolSocketFactory(new DefaultX509TrustManager(), new CertificateStoreX509KeyManager(\n new DisabledCertificateIdentityCallback(),\n new Host(new TestProtocol()), new DisabledCertificateStore()\n ...
{ "fields": [ { "declarator": "log = Logger.getLogger(CustomTrustSSLProtocolSocketFactory.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(CustomTrustSSLProtocolSocketFactory.class);", "type": "Logger", "var_name": "l...
{ "body": "public SSLContext getSSLContext() {\n return context;\n }", "class_method_signature": "CustomTrustSSLProtocolSocketFactory.getSSLContext()", "constructor": false, "full_signature": "public SSLContext getSSLContext()", "identifier": "getSSLContext", "invocations": [], "modifiers": "pub...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1014
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/transfer/upload/CompareFilterTest.java", "identifier": "CompareFilterTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testAcceptDirectory() throws Exception {\n final CompareFilter filter = new CompareFilter(new DisabledUploadSymlinkResolver(),\n new NullSession(new Host(new TestProtocol())), new UploadFilterOptions(),\n new ComparisonServiceFilter(new NullSessio...
{ "fields": [ { "declarator": "log = Logger.getLogger(CompareFilter.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(CompareFilter.class);", "type": "Logger", "var_name": "log" }, { "declarator": "compar...
{ "body": "@Override\n public boolean accept(final Path file, final Local local, final TransferStatus parent) throws BackgroundException {\n if(super.accept(file, local, parent)) {\n final Comparison comparison = comparisonService.compare(file, local);\n switch(comparison) {\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1444
{ "fields": [], "file": "cli/src/test/java/ch/cyberduck/cli/SingleTransferItemFinderTest.java", "identifier": "SingleTransferItemFinderTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testDeferUploadNameFromLocal() throws Exception {\n final CommandLineParser parser = new PosixParser();\n final String temp = System.getProperty(\"java.io.tmpdir\");\n final CommandLine input = parser.parse(TerminalOptionsBuilder.options(), new String[]{\"--uploa...
{ "fields": [ { "declarator": "prefixer\n = new WorkdirPrefixer()", "modifier": "private final", "original_string": "private final WorkdirPrefixer prefixer\n = new WorkdirPrefixer();", "type": "WorkdirPrefixer", "var_name": "prefixer" } ], "file": "cli/s...
{ "body": "@Override\n public Set<TransferItem> find(final CommandLine input, final TerminalAction action, final Path remote) {\n if(input.getOptionValues(action.name()).length == 2) {\n switch(action) {\n case download:\n return new DownloadTransferItemFinder()....
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_811
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/DefaultPathPredicateTest.java", "identifier": "DefaultPathPredicateTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testPredicateVersionIdDirectory() {\n final Path t = new Path(\"/f\", EnumSet.of(Path.Type.directory), new PathAttributes().withVersionId(\"1\"));\n assertTrue(new DefaultPathPredicate(t).test(t));\n assertTrue(new DefaultPathPredicate(t).test(new Path(\"/f\", En...
{ "fields": [ { "declarator": "normalizer = new NFCNormalizer()", "modifier": "private static final", "original_string": "private static final UnicodeNormalizer normalizer = new NFCNormalizer();", "type": "UnicodeNormalizer", "var_name": "normalizer" }, { "declarator": ...
{ "body": "@Override\n public boolean test(final Path test) {\n return this.equals(new DefaultPathPredicate(test));\n }", "class_method_signature": "DefaultPathPredicate.test(final Path test)", "constructor": false, "full_signature": "@Override public boolean test(final Path test)", "identifier":...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_542
{ "fields": [], "file": "webdav/src/test/java/ch/cyberduck/core/dav/DAVDeleteFeatureTest.java", "identifier": "DAVDeleteFeatureTest", "interfaces": "", "superclass": "extends AbstractDAVTest" }
{ "body": "@Test(expected = NotfoundException.class)\n public void testDeleteNotFound() throws Exception {\n final Path test = new Path(new DefaultHomeFinderService(session).find(), UUID.randomUUID().toString(), EnumSet.of(Path.Type.file));\n new DAVDeleteFeature(session).delete(Collections.singleton...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final DAVSession session;", "type": "DAVSession", "var_name": "session" } ], "file": "webdav/src/main/java/ch/cyberduck/core/dav/DAVDeleteFeature.java", "identifier": "DAVDelet...
{ "body": "@Override\n public void delete(final Map<Path, TransferStatus> files, final PasswordCallback prompt, final Callback callback) throws BackgroundException {\n final List<Path> deleted = new ArrayList<Path>();\n for(Map.Entry<Path, TransferStatus> file : files.entrySet()) {\n boole...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_112
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3WriteFeatureTest.java", "identifier": "S3WriteFeatureTest", "interfaces": "", "superclass": "extends AbstractS3Test" }
{ "body": "@Test\n public void testAppendBelowLimit() throws Exception {\n final S3Session session = new S3Session(new Host(new S3Protocol()));\n final S3WriteFeature feature = new S3WriteFeature(session, null, new Find() {\n @Override\n public boolean find(final Path file) {\n ...
{ "fields": [ { "declarator": "log = Logger.getLogger(S3WriteFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3WriteFeature.class);", "type": "Logger", "var_name": "log" }, { "declarator": "pref...
{ "body": "@Override\n public Append append(final Path file, final Long length, final Cache<Path> cache) throws BackgroundException {\n if(length >= preferences.getLong(\"s3.upload.multipart.threshold\")) {\n if(preferences.getBoolean(\"s3.upload.multipart\")) {\n try {\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_406
{ "fields": [], "file": "storegate/src/test/java/ch/cyberduck/core/storegate/StoregateListServiceTest.java", "identifier": "StoregateListServiceTest", "interfaces": "", "superclass": "extends AbstractStoregateTest" }
{ "body": "@Test\n public void testList() throws Exception {\n final StoregateIdProvider nodeid = new StoregateIdProvider(session).withCache(cache);\n final AttributedList<Path> list = new StoregateListService(session, nodeid).list(\n new Path(\"/My files\", EnumSet.of(directory, Path.Type...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final StoregateSession session;", "type": "StoregateSession", "var_name": "session" }, { "declarator": "fileid", "modifier": "private final", "original_string":...
{ "body": "@Override\n public AttributedList<Path> list(final Path directory, final ListProgressListener listener) throws BackgroundException {\n if(directory.isRoot()) {\n final AttributedList<Path> list = new AttributedList<>();\n for(RootFolder root : session.roots()) {\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_22
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3UrlProviderTest.java", "identifier": "S3UrlProviderTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testToTorrentUrlThirdparty() {\n final S3Session session = new S3Session(new Host(new S3Protocol(), \"test-us-east-1-cyberduck\",\n new Credentials(\"anonymous\", null)));\n assertEquals(new DescriptiveUrl(URI.create(\"http://test-us-east-1-cyberduck/c/test%2...
{ "fields": [ { "declarator": "log = Logger.getLogger(S3UrlProvider.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3UrlProvider.class);", "type": "Logger", "var_name": "log" }, { "declarator": "contai...
{ "body": "@Override\n public DescriptiveUrlBag toUrl(final Path file) {\n final DescriptiveUrlBag list = new DescriptiveUrlBag();\n if(file.isFile()) {\n // Publicly accessible URL of given object\n list.add(this.toUrl(file, session.getHost().getProtocol().getScheme(), session....
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1150
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/library/NativeTest.java", "identifier": "NativeTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testLoad() {\n assertFalse(Native.load(\"notfound\"));\n }", "class_method_signature": "NativeTest.testLoad()", "constructor": false, "full_signature": "@Test public void testLoad()", "identifier": "testLoad", "invocations": [ "assertFalse", "load" ], ...
{ "fields": [ { "declarator": "log = Logger.getLogger(Native.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(Native.class);", "type": "Logger", "var_name": "log" }, { "declarator": "lock = new Object()"...
{ "body": "public static boolean load(final String library) {\n synchronized(lock) {\n final String path = Native.getPath(library);\n try {\n // Load using absolute path. Otherwise we may load\n // a library in java.library.path that was not intended\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_955
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/ssl/ThreadLocalHostnameDelegatingTrustManagerTest.java", "identifier": "ThreadLocalHostnameDelegatingTrustManagerTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testSetTarget() {\n assertEquals(\"s3.amazonaws.com\",\n new ThreadLocalHostnameDelegatingTrustManager(new DisabledX509TrustManager(), \"s3.amazonaws.com\").getTarget());\n assertEquals(\"cyberduck.s3.amazonaws.com\",\n new ThreadLocalHostn...
{ "fields": [ { "declarator": "target\n = new ThreadLocal<String>()", "modifier": "private final", "original_string": "private final ThreadLocal<String> target\n = new ThreadLocal<String>();", "type": "ThreadLocal<String>", "var_name": "target" }, { "decla...
{ "body": "public void setTarget(final String hostname) {\n this.target.set(hostname);\n }", "class_method_signature": "ThreadLocalHostnameDelegatingTrustManager.setTarget(final String hostname)", "constructor": false, "full_signature": "public void setTarget(final String hostname)", "identifier": "...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1500
{ "fields": [], "file": "dropbox/src/test/java/ch/cyberduck/core/dropbox/DropboxPathContainerServiceTest.java", "identifier": "DropboxPathContainerServiceTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testGetKey() {\n final DropboxPathContainerService s = new DropboxPathContainerService();\n assertEquals(\"\", s.getKey(new Path(\"/\", EnumSet.of(Path.Type.directory, Path.Type.volume)).withAttributes(new PathAttributes().withVersionId(\"r\"))));\n assertEquals(...
{ "fields": [ { "declarator": "useNamespace = false", "modifier": "private", "original_string": "private boolean useNamespace = false;", "type": "boolean", "var_name": "useNamespace" } ], "file": "dropbox/src/main/java/ch/cyberduck/core/dropbox/DropboxPathContainerService.jav...
{ "body": "@Override\n public String getKey(final Path file) {\n if(PreferencesFactory.get().getBoolean(\"dropbox.business.enable\")) {\n final Path container = this.getContainer(file);\n final String namespace = container.attributes().getVersionId();\n if(StringUtils.isNotB...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1015
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/transfer/upload/LocalPriorityComparatorTest.java", "identifier": "LocalPriorityComparatorTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testCompare() {\n assertEquals(-1, new LocalPriorityComparator().compare(new NullLocal(\"/t\") {\n @Override\n public boolean isFile() {\n return false;\n }\n\n @Override\n public boolean isDirectory() {\n ...
{ "fields": [], "file": "core/src/main/java/ch/cyberduck/core/transfer/upload/LocalPriorityComparator.java", "identifier": "LocalPriorityComparator", "interfaces": "implements Comparator<Local>", "methods": [ { "class_method_signature": "LocalPriorityComparator.compare(final Local o1, final Local o2...
{ "body": "@Override\n public int compare(final Local o1, final Local o2) {\n if(o1.isDirectory() && o2.isDirectory()) {\n return 0;\n }\n if(o1.isFile() && o2.isFile()) {\n return 0;\n }\n if(o1.isDirectory()) {\n return -1;\n }\n i...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_810
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/DefaultPathPredicateTest.java", "identifier": "DefaultPathPredicateTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testPredicateVersionIdFile() {\n final Path t = new Path(\"/f\", EnumSet.of(Path.Type.file), new PathAttributes().withVersionId(\"1\"));\n assertTrue(new DefaultPathPredicate(t).test(t));\n assertTrue(new DefaultPathPredicate(t).test(new Path(\"/f\", EnumSet.of(P...
{ "fields": [ { "declarator": "normalizer = new NFCNormalizer()", "modifier": "private static final", "original_string": "private static final UnicodeNormalizer normalizer = new NFCNormalizer();", "type": "UnicodeNormalizer", "var_name": "normalizer" }, { "declarator": ...
{ "body": "@Override\n public boolean test(final Path test) {\n return this.equals(new DefaultPathPredicate(test));\n }", "class_method_signature": "DefaultPathPredicate.test(final Path test)", "constructor": false, "full_signature": "@Override public boolean test(final Path test)", "identifier":...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1445
{ "fields": [], "file": "cli/src/test/java/ch/cyberduck/cli/SingleTransferItemFinderTest.java", "identifier": "SingleTransferItemFinderTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testUploadDirectory() throws Exception {\n final CommandLineParser parser = new PosixParser();\n final CommandLine input = parser.parse(TerminalOptionsBuilder.options(), new String[]{\"--upload\", \"ftps://test.cyberduck.ch/remote/\", System.getProperty(\"java.io.tmpdir...
{ "fields": [ { "declarator": "prefixer\n = new WorkdirPrefixer()", "modifier": "private final", "original_string": "private final WorkdirPrefixer prefixer\n = new WorkdirPrefixer();", "type": "WorkdirPrefixer", "var_name": "prefixer" } ], "file": "cli/s...
{ "body": "@Override\n public Set<TransferItem> find(final CommandLine input, final TerminalAction action, final Path remote) {\n if(input.getOptionValues(action.name()).length == 2) {\n switch(action) {\n case download:\n return new DownloadTransferItemFinder()....
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_543
{ "fields": [], "file": "webdav/src/test/java/ch/cyberduck/core/dav/DAVFindFeatureTest.java", "identifier": "DAVFindFeatureTest", "interfaces": "", "superclass": "extends AbstractDAVTest" }
{ "body": "@Test\n public void testFind() throws Exception {\n assertTrue(new DAVFindFeature(session).find(new DefaultHomeFinderService(session).find()));\n assertFalse(new DAVFindFeature(session).find(\n new Path(new DefaultHomeFinderService(session).find(), UUID.randomUUID().toString(), ...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final DAVSession session;", "type": "DAVSession", "var_name": "session" }, { "declarator": "cache = PathCache.empty()", "modifier": "private", "original_string"...
{ "body": "@Override\n public boolean find(final Path file) throws BackgroundException {\n if(file.isRoot()) {\n return true;\n }\n try {\n try {\n try {\n final HttpHead request = new HttpHead(new DAVPathEncoder().encode(file));\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_113
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3WriteFeatureTest.java", "identifier": "S3WriteFeatureTest", "interfaces": "", "superclass": "extends AbstractS3Test" }
{ "body": "@Test\n public void testSize() throws Exception {\n final S3Session session = new S3Session(new Host(new S3Protocol()));\n final S3WriteFeature feature = new S3WriteFeature(session, null, new Find() {\n @Override\n public boolean find(final Path file) {\n ...
{ "fields": [ { "declarator": "log = Logger.getLogger(S3WriteFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3WriteFeature.class);", "type": "Logger", "var_name": "log" }, { "declarator": "pref...
{ "body": "@Override\n public Append append(final Path file, final Long length, final Cache<Path> cache) throws BackgroundException {\n if(length >= preferences.getLong(\"s3.upload.multipart.threshold\")) {\n if(preferences.getBoolean(\"s3.upload.multipart\")) {\n try {\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1296
{ "fields": [], "file": "ssh/src/test/java/ch/cyberduck/core/sftp/SFTPAttributesFinderFeatureTest.java", "identifier": "SFTPAttributesFinderFeatureTest", "interfaces": "", "superclass": "extends AbstractSFTPTest" }
{ "body": "@Test\n public void testFindSymbolicLink() throws Exception {\n final Path file = new SFTPTouchFeature(session).touch(new Path(new SFTPHomeDirectoryService(session).find(), new AlphanumericRandomStringService().random(), EnumSet.of(Path.Type.file)), new TransferStatus());\n final Path syml...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final SFTPSession session;", "type": "SFTPSession", "var_name": "session" } ], "file": "ssh/src/main/java/ch/cyberduck/core/sftp/SFTPAttributesFinderFeature.java", "identifier"...
{ "body": "@Override\n public PathAttributes find(final Path file) throws BackgroundException {\n if(file.isRoot()) {\n return PathAttributes.EMPTY;\n }\n try {\n final FileAttributes stat;\n if(file.isSymbolicLink()) {\n stat = session.sftp().ls...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_390
{ "fields": [], "file": "googledrive/src/test/java/ch/cyberduck/core/googledrive/DriveSessionTest.java", "identifier": "DriveSessionTest", "interfaces": "", "superclass": "extends AbstractDriveTest" }
{ "body": "@Test\n public void testConnect() throws Exception {\n assertTrue(session.isConnected());\n session.close();\n assertFalse(session.isConnected());\n }", "class_method_signature": "DriveSessionTest.testConnect()", "constructor": false, "full_signature": "@Test public void te...
{ "fields": [ { "declarator": "log = Logger.getLogger(DriveSession.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(DriveSession.class);", "type": "Logger", "var_name": "log" }, { "declarator": "transpor...
{ "body": "@Override\n protected Drive connect(final Proxy proxy, final HostKeyCallback callback, final LoginCallback prompt) {\n final HttpClientBuilder configuration = builder.build(proxy, this, prompt);\n authorizationService = new OAuth2RequestInterceptor(configuration.build(), host.getProtocol()...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_685
{ "fields": [], "file": "core/dylib/src/test/java/ch/cyberduck/core/resources/NSImageIconCacheTest.java", "identifier": "NSImageIconCacheTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testDocumentIconNullExtension() {\n final NSImage icon = new NSImageIconCache().documentIcon(null, 64);\n assertNotNull(icon);\n assertTrue(icon.isValid());\n assertFalse(icon.isTemplate());\n assertEquals(64, icon.size().width.intValue());\n ...
{ "fields": [ { "declarator": "log = Logger.getLogger(NSImageIconCache.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(NSImageIconCache.class);", "type": "Logger", "var_name": "log" }, { "declarator": "...
{ "body": "@Override\n public NSImage documentIcon(final String extension, final Integer size) {\n NSImage image = this.load(extension, size);\n if(null == image) {\n return this.cache(extension,\n this.convert(extension, NSWorkspace.sharedWorkspace().iconForFileType(extensi...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1279
{ "fields": [], "file": "ssh/src/test/java/ch/cyberduck/core/sftp/SFTPListServiceTest.java", "identifier": "SFTPListServiceTest", "interfaces": "", "superclass": "extends AbstractSFTPTest" }
{ "body": "@Test\n public void testList() throws Exception {\n final Path home = new SFTPHomeDirectoryService(session).find();\n final Path file = new Path(home, new AlphanumericRandomStringService().random(), EnumSet.of(Path.Type.file));\n final Path symlinkRelative = new Path(home, new Alpha...
{ "fields": [ { "declarator": "log = Logger.getLogger(SFTPListService.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SFTPListService.class);", "type": "Logger", "var_name": "log" }, { "declarator": "se...
{ "body": "@Override\n public AttributedList<Path> list(final Path directory, final ListProgressListener listener) throws BackgroundException {\n try {\n final AttributedList<Path> children = new AttributedList<Path>();\n final RemoteDirectory handle = session.sftp().openDir(directory....
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_902
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/text/NaturalOrderComparatorTest.java", "identifier": "NaturalOrderComparatorTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testCompare() {\n assertEquals(-1, new NaturalOrderComparator().compare(\"123a\", \"a\"));\n assertEquals(-1, new NaturalOrderComparator().compare(\"365\", \"400\"));\n }", "class_method_signature": "NaturalOrderComparatorTest.testCompare()", "constructor": false...
{ "fields": [ { "declarator": "serialVersionUID = -5851677380348435176L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = -5851677380348435176L;", "type": "long", "var_name": "serialVersionUID" }, { "declarator": "col...
{ "body": "@Override\n public int compare(final String s1, final String s2) {\n return collator.compare(s1, s2);\n }", "class_method_signature": "NaturalOrderComparator.compare(final String s1, final String s2)", "constructor": false, "full_signature": "@Override public int compare(final String s1,...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1107
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/local/DefaultTemporaryFileServiceTest.java", "identifier": "DefaultTemporaryFileServiceTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testPathTooLong() {\n final String temp = StringUtils.removeEnd(System.getProperty(\"java.io.tmpdir\"), File.separator);\n final String testPathDirectory = \"/Lorem/ipsum/dolor/sit/amet/consetetur/sadipscing/elitr/sed/diam/nonumy/eirmod/tempor/invidunt/ut/labore/et/dolo...
{ "fields": [ { "declarator": "delimiter\n = PreferencesFactory.get().getProperty(\"local.delimiter\")", "modifier": "private final", "original_string": "private final String delimiter\n = PreferencesFactory.get().getProperty(\"local.delimiter\");", "type": "String", "v...
{ "body": "@Override\n public Local create(final Path file) {\n return this.create(new UUIDRandomStringService().random(), file);\n }", "class_method_signature": "DefaultTemporaryFileService.create(final Path file)", "constructor": false, "full_signature": "@Override public Local create(final Path ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_75
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3PresignedUrlProviderTest.java", "identifier": "S3PresignedUrlProviderTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testCreateEuCentralAtSign() throws Exception {\n final Calendar expiry = Calendar.getInstance(TimeZone.getTimeZone(\"UTC\"));\n expiry.add(Calendar.MILLISECOND, (int) TimeUnit.DAYS.toMillis(7));\n final String url = new S3PresignedUrlProvider().create(new Host(ne...
{ "fields": [], "file": "s3/src/main/java/ch/cyberduck/core/s3/S3PresignedUrlProvider.java", "identifier": "S3PresignedUrlProvider", "interfaces": "", "methods": [ { "class_method_signature": "S3PresignedUrlProvider.create(final Host host, final String user, final String secret,\n ...
{ "body": "public String create(final Host host, final String user, final String secret,\n final String bucket, String region, final String key,\n final String method, final long expiry) {\n final S3Protocol.AuthenticationHeaderSignatureVersion signature;\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_451
{ "fields": [], "file": "dracoon/src/test/java/ch/cyberduck/core/sds/SDSSharesUrlProviderTest.java", "identifier": "SDSSharesUrlProviderTest", "interfaces": "", "superclass": "extends AbstractSDSTest" }
{ "body": "@Test\n public void testShareFile() throws Exception {\n final SDSNodeIdProvider nodeid = new SDSNodeIdProvider(session).withCache(cache);\n final Path room = new SDSDirectoryFeature(session, nodeid).mkdir(new Path(new AlphanumericRandomStringService().random(), EnumSet.of(Path.Type.direct...
{ "fields": [ { "declarator": "log = Logger.getLogger(SDSSharesUrlProvider.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SDSSharesUrlProvider.class);", "type": "Logger", "var_name": "log" }, { "declar...
{ "body": "@Override\n public DescriptiveUrl toDownloadUrl(final Path file, CreateDownloadShareRequest options, final PasswordCallback callback) throws BackgroundException {\n try {\n if(log.isDebugEnabled()) {\n log.debug(String.format(\"Create download share for %s\", file));\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_144
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3ObjectListServiceTest.java", "identifier": "S3ObjectListServiceTest", "interfaces": "", "superclass": "extends AbstractS3Test" }
{ "body": "@Test\n public void testDirectory() throws Exception {\n final Path bucket = new Path(\"test-us-east-1-cyberduck\", EnumSet.of(Path.Type.directory, Path.Type.volume));\n final Path directory = new S3DirectoryFeature(session, new S3WriteFeature(session)).mkdir(new Path(bucket, new Alphanume...
{ "fields": [ { "declarator": "log = Logger.getLogger(S3ObjectListService.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3ObjectListService.class);", "type": "Logger", "var_name": "log" }, { "declarat...
{ "body": "@Override\n public AttributedList<Path> list(final Path directory, final ListProgressListener listener) throws BackgroundException {\n return this.list(directory, listener, String.valueOf(Path.DELIMITER));\n }", "class_method_signature": "S3ObjectListService.list(final Path directory, final ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_514
{ "fields": [], "file": "dracoon/src/test/java/ch/cyberduck/core/sds/SDSTouchFeatureTest.java", "identifier": "SDSTouchFeatureTest", "interfaces": "", "superclass": "extends AbstractSDSTest" }
{ "body": "@Test\n public void testTouch() throws Exception {\n final SDSNodeIdProvider nodeid = new SDSNodeIdProvider(session).withCache(cache);\n final Path room = new SDSDirectoryFeature(session, nodeid).mkdir(\n new Path(new AlphanumericRandomStringService().random(), EnumSet.of(Path.T...
{ "fields": [ { "declarator": "log = Logger.getLogger(SDSTouchFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SDSTouchFeature.class);", "type": "Logger", "var_name": "log" }, { "declarator": "se...
{ "body": "@Override\n public Path touch(final Path file, final TransferStatus status) throws BackgroundException {\n try {\n if(nodeid.isEncrypted(file)) {\n status.setFilekey(nodeid.getFileKey());\n }\n final StatusOutputStream<VersionId> out = writer.write(...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_847
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/io/MD5ChecksumComputeTest.java", "identifier": "MD5ChecksumComputeTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testNormalize() throws Exception {\n assertEquals(\"a43c1b0aa53a0c908810c06ab1ff3967\",\n new MD5ChecksumCompute().compute(IOUtils.toInputStream(\"input\", Charset.defaultCharset()),\n new TransferStatus()).hash);\n assertEquals(\"a43c1b0aa53a0...
{ "fields": [], "file": "core/src/main/java/ch/cyberduck/core/io/MD5ChecksumCompute.java", "identifier": "MD5ChecksumCompute", "interfaces": "", "methods": [ { "class_method_signature": "MD5ChecksumCompute.compute(final InputStream in, final TransferStatus status)", "constructor": false, ...
{ "body": "@Override\n public Checksum compute(final InputStream in, final TransferStatus status) throws ChecksumException {\n return new Checksum(HashAlgorithm.md5, Hex.encodeHexString(this.digest(\"MD5\",\n this.normalize(in, status))));\n }", "class_method_signature": "MD5ChecksumCompute....
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1412
{ "fields": [], "file": "openstack/src/test/java/ch/cyberduck/core/openstack/SwiftDeleteFeatureTest.java", "identifier": "SwiftDeleteFeatureTest", "interfaces": "", "superclass": "extends AbstractSwiftTest" }
{ "body": "@Test(expected = NotfoundException.class)\n public void testDeleteNotFoundBucket() throws Exception {\n final Path container = new Path(UUID.randomUUID().toString(), EnumSet.of(Path.Type.directory, Path.Type.volume));\n container.attributes().setRegion(\"IAD\");\n new SwiftDeleteFea...
{ "fields": [ { "declarator": "log = Logger.getLogger(SwiftDeleteFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SwiftDeleteFeature.class);", "type": "Logger", "var_name": "log" }, { "declarator...
{ "body": "@Override\n public void delete(final Map<Path, TransferStatus> files, final PasswordCallback prompt, final Callback callback) throws BackgroundException {\n this.delete(files, prompt, callback, true);\n }", "class_method_signature": "SwiftDeleteFeature.delete(final Map<Path, TransferStatus> ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1042
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/transfer/CopyTransferTest.java", "identifier": "CopyTransferTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testSerialize() {\n final Path test = new Path(\"t\", EnumSet.of(Path.Type.file));\n CopyTransfer t = new CopyTransfer(new Host(new TestProtocol()),\n new Host(new TestProtocol()), Collections.singletonMap(test, new Path(\"d\", EnumSet.of(Path.Type.file))...
{ "fields": [ { "declarator": "log = Logger.getLogger(CopyTransfer.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(CopyTransfer.class);", "type": "Logger", "var_name": "log" }, { "declarator": "filter =...
{ "body": "@Override\n public <T> T serialize(final Serializer dict) {\n dict.setStringForKey(this.getType().name(), \"Type\");\n dict.setObjectForKey(host, \"Host\");\n if(destination != null) {\n dict.setObjectForKey(destination, \"Destination\");\n }\n dict.setListF...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_797
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/ui/comparator/GroupComparatorTest.java", "identifier": "GroupComparatorTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testCompareFirst() {\n assertEquals(0,\n new GroupComparator(true).compareFirst(new Path(\"/a\", EnumSet.of(Path.Type.file)), new Path(\"/b\", EnumSet.of(Path.Type.file))));\n final Path p = new Path(\"/a\", EnumSet.of(Path.Type.file));\n p.attribu...
{ "fields": [ { "declarator": "serialVersionUID = 6549899374390308835L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = 6549899374390308835L;", "type": "long", "var_name": "serialVersionUID" } ], "file": "core/src/main/jav...
{ "body": "@Override\n protected int compareFirst(final Path p1, final Path p2) {\n if(StringUtils.isBlank(p1.attributes().getGroup()) && StringUtils.isBlank(p2.attributes().getGroup())) {\n return 0;\n }\n if(StringUtils.isBlank(p1.attributes().getGroup())) {\n return -1...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1384
{ "fields": [], "file": "openstack/src/test/java/ch/cyberduck/core/openstack/SwiftDistributionPurgeFeatureTest.java", "identifier": "SwiftDistributionPurgeFeatureTest", "interfaces": "", "superclass": "extends AbstractSwiftTest" }
{ "body": "@Test(expected = InteroperabilityException.class)\n public void testInvalidateContainer() throws Exception {\n final SwiftDistributionPurgeFeature feature = new SwiftDistributionPurgeFeature(session);\n final Path container = new Path(\"test.cyberduck.ch\", EnumSet.of(Path.Type.volume, Pat...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final SwiftSession session;", "type": "SwiftSession", "var_name": "session" }, { "declarator": "containerService\n = new PathContainerService()", "modifier...
{ "body": "@Override\n public void invalidate(final Path container, final Distribution.Method method, final List<Path> files, final LoginCallback prompt) throws BackgroundException {\n try {\n for(Path file : files) {\n if(containerService.isContainer(file)) {\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_282
{ "fields": [ { "declarator": "parser", "modifier": "private", "original_string": "private FTPFileEntryParser parser;", "type": "FTPFileEntryParser", "var_name": "parser" } ], "file": "ftp/src/test/java/ch/cyberduck/core/ftp/parser/TrellixFTPEntryParserTest.java", "identifi...
{ "body": "@Test\n public void testParse() {\n FTPFile parsed;\n\n //#1213\n parsed = parser.parseFTPEntry(\n \"-rw-r--r-- FTP User 10439 Apr 20 05:29 ASCheckbox_2_0.zip\"\n );\n assertNotNull(parsed);\n assertEquals(\"ASCheckbox_2_0.zip\", parsed.getNam...
{ "fields": [ { "declarator": "REGEX =\n \"([bcdlfmpSs-])\"\n + \"(((r|-)(w|-)([xsStTL-]))((r|-)(w|-)([xsStTL-]))((r|-)(w|-)([xsStTL-])))\\\\+?\\\\s+\"\n + \"(\\\\S+)\\\\s+\"\n + \"(?:(\\\\S+(?:\\\\s\\\\S+)*)\\\\s+)?\"\n ...
{ "body": "@Override\n public FTPFile parseFTPEntry(String entry) {\n if(matches(entry)) {\n String typeStr = group(1);\n String usr = group(15);\n String grp = group(16);\n String filesize = group(17);\n String datestr = group(18) + \" \" + group(19);\...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_778
{ "fields": [], "file": "core/dylib/src/test/java/ch/cyberduck/core/threading/AutoreleaseActionOperationBatcherTest.java", "identifier": "AutoreleaseActionOperationBatcherTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testOperate() {\n new AutoreleaseActionOperationBatcher().operate();\n }", "class_method_signature": "AutoreleaseActionOperationBatcherTest.testOperate()", "constructor": false, "full_signature": "@Test public void testOperate()", "identifier": "testOperate", "inv...
{ "fields": [ { "declarator": "impl = AutoreleaseBatcher.forThread(1)", "modifier": "private final", "original_string": "private final AutoreleaseBatcher impl = AutoreleaseBatcher.forThread(1);", "type": "AutoreleaseBatcher", "var_name": "impl" } ], "file": "core/dylib/src/ma...
{ "body": "public void operate() {\n impl.operate();\n }", "class_method_signature": "AutoreleaseActionOperationBatcher.operate()", "constructor": false, "full_signature": "public void operate()", "identifier": "operate", "invocations": [ "operate" ], "modifiers": "public", "parameters":...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_328
{ "fields": [], "file": "nio/src/test/java/ch/cyberduck/core/nio/LocalMoveFeatureTest.java", "identifier": "LocalMoveFeatureTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testMoveDirectory() throws Exception {\n final LocalSession session = new LocalSession(new Host(new LocalProtocol(), new LocalProtocol().getDefaultHostname()));\n session.open(Proxy.DIRECT, new DisabledHostKeyCallback(), new DisabledLoginCallback());\n session.lo...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final LocalSession session;", "type": "LocalSession", "var_name": "session" } ], "file": "nio/src/main/java/ch/cyberduck/core/nio/LocalMoveFeature.java", "identifier": "LocalMo...
{ "body": "@Override\n public Path move(final Path file, final Path renamed, final TransferStatus status, final Delete.Callback callback, final ConnectionCallback connectionCallback) throws BackgroundException {\n if(!new LocalFindFeature(session).find(file)) {\n throw new NotfoundException(file....
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_447
{ "fields": [], "file": "dracoon/src/test/java/ch/cyberduck/core/sds/SDSExceptionMappingServiceTest.java", "identifier": "SDSExceptionMappingServiceTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testMap() {\n final BackgroundException e = new SDSExceptionMappingService().map(new ApiException(\"m\", 403, Collections.emptyMap(),\n \"{\\\"errorCode\\\" = -40761}\"));\n assertEquals(\"Error -40761. Please contact your web hosting service provider for ass...
{ "fields": [ { "declarator": "log = Logger.getLogger(SDSExceptionMappingService.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SDSExceptionMappingService.class);", "type": "Logger", "var_name": "log" } ], "...
{ "body": "@Override\n public BackgroundException map(final ApiException failure) {\n for(Throwable cause : ExceptionUtils.getThrowableList(failure)) {\n if(cause instanceof SocketException) {\n // Map Connection has been shutdown: javax.net.ssl.SSLException: java.net.SocketExcepti...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_63
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3MetadataFeatureTest.java", "identifier": "S3MetadataFeatureTest", "interfaces": "", "superclass": "extends AbstractS3Test" }
{ "body": "@Test\n public void testGetMetadataFile() throws Exception {\n final Path container = new Path(\"versioning-test-us-east-1-cyberduck\", EnumSet.of(Path.Type.volume));\n final Path test = new Path(container, new AlphanumericRandomStringService().random(), EnumSet.of(Path.Type.file));\n ...
{ "fields": [ { "declarator": "log = Logger.getLogger(S3MetadataFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3MetadataFeature.class);", "type": "Logger", "var_name": "log" }, { "declarator":...
{ "body": "@Override\n public Map<String, String> getMetadata(final Path file) throws BackgroundException {\n return new S3AttributesFinderFeature(session).find(file).getMetadata();\n }", "class_method_signature": "S3MetadataFeature.getMetadata(final Path file)", "constructor": false, "full_signatu...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1111
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/local/DefaultLocalTouchFeatureTest.java", "identifier": "DefaultLocalTouchFeatureTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testFailure() {\n Local l = new Local(\"/\" + UUID.randomUUID().toString());\n final DefaultLocalTouchFeature f = new DefaultLocalTouchFeature();\n try {\n f.touch(l);\n }\n catch(AccessDeniedException e) {\n final String s = l...
{ "fields": [ { "declarator": "log = Logger.getLogger(DefaultLocalTouchFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(DefaultLocalTouchFeature.class);", "type": "Logger", "var_name": "log" } ], "file...
{ "body": "@Override\n public void touch(final Local file) throws AccessDeniedException {\n try {\n try {\n Files.createFile(Paths.get(file.getAbsolute()));\n }\n catch(NoSuchFileException e) {\n final Local parent = file.getParent();\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_914
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/worker/SearchWorkerTest.java", "identifier": "SearchWorkerTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testRepeatedRunWithCache() throws Exception {\n final PathCache cache = new PathCache(Integer.MAX_VALUE);\n\n final AttributedList<Path> root = new AttributedList<>();\n root.add(new Path(\"/t1.png\", EnumSet.of(Path.Type.file)));\n root.add(new Path(\"/fo...
{ "fields": [ { "declarator": "log = Logger.getLogger(SearchWorker.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SearchWorker.class);", "type": "Logger", "var_name": "log" }, { "declarator": "director...
{ "body": "@Override\n public AttributedList<Path> run(final Session<?> session) throws BackgroundException {\n // Run recursively\n final Search feature = session.getFeature(Search.class).withCache(cache);\n if(log.isDebugEnabled()) {\n log.debug(String.format(\"Run with feature %s...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1054
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/transfer/normalizer/CopyRootPathsNormalizerTest.java", "identifier": "CopyRootPathsNormalizerTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testNormalize() {\n CopyRootPathsNormalizer normalizer = new CopyRootPathsNormalizer();\n final HashMap<Path, Path> files = new HashMap<Path, Path>();\n files.put(new Path(\"/p\", EnumSet.of(Path.Type.directory)), new Path(\"/d\", EnumSet.of(Path.Type.directory))...
{ "fields": [ { "declarator": "log = Logger.getLogger(CopyRootPathsNormalizer.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(CopyRootPathsNormalizer.class);", "type": "Logger", "var_name": "log" } ], "file":...
{ "body": "@Override\n public Map<Path, Path> normalize(final Map<Path, Path> files) {\n final Map<Path, Path> normalized = new HashMap<Path, Path>();\n Iterator<Path> sourcesIter = files.keySet().iterator();\n Iterator<Path> destinationsIter = files.values().iterator();\n while(sources...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1404
{ "fields": [], "file": "openstack/src/test/java/ch/cyberduck/core/openstack/SwiftAttributesFinderFeatureTest.java", "identifier": "SwiftAttributesFinderFeatureTest", "interfaces": "", "superclass": "extends AbstractSwiftTest" }
{ "body": "@Test\n public void testFindContainer() throws Exception {\n final Path container = new Path(\"test.cyberduck.ch\", EnumSet.of(Path.Type.directory, Path.Type.volume));\n container.attributes().setRegion(\"IAD\");\n final PathAttributes attributes = new SwiftAttributesFinderFeature(s...
{ "fields": [ { "declarator": "log = Logger.getLogger(SwiftAttributesFinderFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SwiftAttributesFinderFeature.class);", "type": "Logger", "var_name": "log" }, ...
{ "body": "@Override\n public PathAttributes find(final Path file) throws BackgroundException {\n if(file.isRoot()) {\n return PathAttributes.EMPTY;\n }\n final Region region = regionService.lookup(file);\n try {\n if(containerService.isContainer(file)) {\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_851
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/io/FileBufferTest.java", "identifier": "FileBufferTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testTruncate() throws Exception {\n final FileBuffer buffer = new FileBuffer();\n assertEquals(0L, buffer.length(), 0L);\n final byte[] chunk = RandomUtils.nextBytes(100);\n buffer.write(chunk, 0L);\n assertEquals(100L, buffer.length(), 0L);\n ...
{ "fields": [ { "declarator": "log = Logger.getLogger(FileBuffer.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(FileBuffer.class);", "type": "Logger", "var_name": "log" }, { "declarator": "temporary", ...
{ "body": "@Override\n public void truncate(final Long length) {\n this.length = length;\n if(temporary.exists()) {\n try {\n final RandomAccessFile file = random();\n if(length < file.length()) {\n // Truncate current\n f...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_502
{ "fields": [], "file": "dracoon/src/test/java/ch/cyberduck/core/sds/triplecrypt/TripleCryptReadFeatureTest.java", "identifier": "TripleCryptReadFeatureTest", "interfaces": "", "superclass": "extends AbstractSDSTest" }
{ "body": "@Test\n public void testPartialRead() throws Exception {\n final Path room = new Path(\"test\", EnumSet.of(Path.Type.directory, Path.Type.volume, Path.Type.triplecrypt));\n final byte[] content = RandomUtils.nextBytes(32769);\n final TransferStatus status = new TransferStatus();\n ...
{ "fields": [ { "declarator": "log = Logger.getLogger(TripleCryptReadFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(TripleCryptReadFeature.class);", "type": "Logger", "var_name": "log" }, { "de...
{ "body": "@Override\n public InputStream read(final Path file, final TransferStatus status, final ConnectionCallback callback) throws BackgroundException {\n try {\n final FileKey key = new NodesApi(session.getClient()).requestUserFileKey(\n Long.parseLong(nodeid.getFileid(file, n...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_152
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3ObjectListServiceTest.java", "identifier": "S3ObjectListServiceTest", "interfaces": "", "superclass": "extends AbstractS3Test" }
{ "body": "@Test\n public void testListPlaceholder() throws Exception {\n final Path container = new Path(\"test-us-east-1-cyberduck\", EnumSet.of(Path.Type.directory, Path.Type.volume));\n container.attributes().setRegion(\"us-east-1\");\n final Path placeholder = new S3DirectoryFeature(sessi...
{ "fields": [ { "declarator": "log = Logger.getLogger(S3ObjectListService.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3ObjectListService.class);", "type": "Logger", "var_name": "log" }, { "declarat...
{ "body": "@Override\n public AttributedList<Path> list(final Path directory, final ListProgressListener listener) throws BackgroundException {\n return this.list(directory, listener, String.valueOf(Path.DELIMITER));\n }", "class_method_signature": "S3ObjectListService.list(final Path directory, final ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_781
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/ui/browser/DownloadDirectoryFinderTest.java", "identifier": "DownloadDirectoryFinderTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testFind() throws Exception {\n final Host host = new Host(new TestProtocol());\n assertNull(host.getDownloadFolder());\n final DownloadDirectoryFinder finder = new DownloadDirectoryFinder();\n assertEquals(System.getProperty(\"user.dir\"), finder.find(hos...
{ "fields": [ { "declarator": "log = Logger.getLogger(DownloadDirectoryFinder.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(DownloadDirectoryFinder.class);", "type": "Logger", "var_name": "log" }, { "...
{ "body": "@Override\n public Local find(final Host bookmark) {\n if(null != bookmark.getDownloadFolder()) {\n if(bookmark.getDownloadFolder().exists()) {\n return bookmark.getDownloadFolder();\n }\n }\n final Local directory = LocalFactory.get(preferences....
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_294
{ "fields": [], "file": "azure/src/test/java/ch/cyberduck/core/azure/AzureDeleteFeatureTest.java", "identifier": "AzureDeleteFeatureTest", "interfaces": "", "superclass": "" }
{ "body": "@Test(expected = NotfoundException.class)\n public void testDeleteNotFoundBucket() throws Exception {\n final Host host = new Host(new AzureProtocol(), \"kahy9boj3eib.blob.core.windows.net\", new Credentials(\n System.getProperties().getProperty(\"azure.account\"), System.getProper...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final AzureSession session;", "type": "AzureSession", "var_name": "session" }, { "declarator": "context", "modifier": "private final", "original_string": "priva...
{ "body": "@Override\n public void delete(final Map<Path, TransferStatus> files, final PasswordCallback prompt, final Callback callback) throws BackgroundException {\n final List<Path> containers = new ArrayList<Path>();\n for(Path file : files.keySet()) {\n if(containerService.isContainer...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1392
{ "fields": [], "file": "openstack/src/test/java/ch/cyberduck/core/openstack/SwiftAuthenticationServiceTest.java", "identifier": "SwiftAuthenticationServiceTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testProfileLondon() throws Exception {\n final SwiftProtocol protocol = new SwiftProtocol() {\n @Override\n public String getContext() {\n return \"/v2.0/tokens\";\n }\n };\n final SwiftAuthenticationService s = new...
{ "fields": [ { "declarator": "log = Logger.getLogger(SwiftAuthenticationService.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SwiftAuthenticationService.class);", "type": "Logger", "var_name": "log" } ], "...
{ "body": "public Set<? extends AuthenticationRequest> getRequest(final Host bookmark, final LoginCallback prompt)\n throws LoginCanceledException {\n final StringBuilder url = new StringBuilder();\n url.append(bookmark.getProtocol().getScheme().toString()).append(\"://\");\n url.appen...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1238
{ "fields": [], "file": "backblaze/src/test/java/ch/cyberduck/core/b2/B2LargeCopyFeatureTest.java", "identifier": "B2LargeCopyFeatureTest", "interfaces": "", "superclass": "extends AbstractB2Test" }
{ "body": "@Test\n public void testCopyDifferentBucket() throws Exception {\n final B2FileidProvider fileid = new B2FileidProvider(session).withCache(cache);\n final Path container = new Path(\"test-cyberduck\", EnumSet.of(Path.Type.directory, Path.Type.volume));\n final Path target = new B2Di...
{ "fields": [ { "declarator": "log = Logger.getLogger(B2LargeCopyFeature.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(B2LargeCopyFeature.class);", "type": "Logger", "var_name": "log" }, { "declarator...
{ "body": "@Override\n public Path copy(final Path source, final Path target, final TransferStatus status, final ConnectionCallback callback) throws BackgroundException {\n final ThreadPool pool = ThreadPoolFactory.get(\"largeupload\", concurrency);\n try {\n final Map<String, String> file...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_943
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/PathNormalizerTest.java", "identifier": "PathNormalizerTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testPathName() {\n {\n Path path = new Path(PathNormalizer.normalize(\n \"/path/to/file/\"), EnumSet.of(Path.Type.directory));\n assertEquals(\"file\", path.getName());\n assertEquals(\"/path/to/file\", path.getAbsolute());\n ...
{ "fields": [ { "declarator": "IS_ENABLED = PreferencesFactory.get().getBoolean(\"path.normalize\")", "modifier": "private static final", "original_string": "private static final boolean IS_ENABLED = PreferencesFactory.get().getBoolean(\"path.normalize\");", "type": "boolean", "var_n...
{ "body": "public static String normalize(final String path) {\n return normalize(path, true);\n }", "class_method_signature": "PathNormalizer.normalize(final String path)", "constructor": false, "full_signature": "public static String normalize(final String path)", "identifier": "normalize", "inv...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1146
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/CredentialsTest.java", "identifier": "CredentialsTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testLoginWithoutPass() {\n Credentials credentials = new Credentials(\"guest\", null);\n assertFalse(credentials.validate(new TestProtocol(Scheme.ftp), new LoginOptions()));\n }", "class_method_signature": "CredentialsTest.testLoginWithoutPass()", "constructor": ...
{ "fields": [ { "declarator": "user = StringUtils.EMPTY", "modifier": "private", "original_string": "private String user = StringUtils.EMPTY;", "type": "String", "var_name": "user" }, { "declarator": "password = StringUtils.EMPTY", "modifier": "private", "or...
{ "body": "public boolean validate(final Protocol protocol, final LoginOptions options) {\n return protocol.validate(this, options);\n }", "class_method_signature": "Credentials.validate(final Protocol protocol, final LoginOptions options)", "constructor": false, "full_signature": "public boolean vali...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_34
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3SingleUploadServiceTest.java", "identifier": "S3SingleUploadServiceTest", "interfaces": "", "superclass": "extends AbstractS3Test" }
{ "body": "@Test\n public void testUpload() throws Exception {\n final S3SingleUploadService service = new S3SingleUploadService(session, new S3WriteFeature(session, new S3DisabledMultipartService()));\n final Path container = new Path(\"test-us-east-1-cyberduck\", EnumSet.of(Path.Type.directory, Pat...
{ "fields": [ { "declarator": "log = Logger.getLogger(S3SingleUploadService.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3SingleUploadService.class);", "type": "Logger", "var_name": "log" }, { "decl...
{ "body": "@Override\n public StorageObject upload(final Path file, final Local local, final BandwidthThrottle throttle,\n final StreamListener listener, final TransferStatus status, final ConnectionCallback callback) throws BackgroundException {\n final S3Protocol.Authenticat...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_410
{ "fields": [], "file": "storegate/src/test/java/ch/cyberduck/core/storegate/StoregateMoveFeatureTest.java", "identifier": "StoregateMoveFeatureTest", "interfaces": "", "superclass": "extends AbstractStoregateTest" }
{ "body": "@Test\n public void testMove() throws Exception {\n final StoregateIdProvider nodeid = new StoregateIdProvider(session).withCache(cache);\n final Path room = new StoregateDirectoryFeature(session, nodeid).mkdir(\n new Path(String.format(\"/My files/%s\", new AlphanumericRandomSt...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final StoregateSession session;", "type": "StoregateSession", "var_name": "session" }, { "declarator": "fileid", "modifier": "private final", "original_string":...
{ "body": "@Override\n public Path move(final Path file, final Path renamed, final TransferStatus status, final Delete.Callback delete, final ConnectionCallback callback) throws BackgroundException {\n try {\n final StoregateApiClient client = session.getClient();\n final MoveFileReque...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_105
{ "fields": [], "file": "s3/src/test/java/ch/cyberduck/core/s3/S3VersionedObjectListServiceTest.java", "identifier": "S3VersionedObjectListServiceTest", "interfaces": "", "superclass": "extends AbstractS3Test" }
{ "body": "@Test\n public void testListFilePlusCharacter() throws Exception {\n final Path container = new Path(\"versioning-test-us-east-1-cyberduck\", EnumSet.of(Path.Type.directory, Path.Type.volume));\n container.attributes().setRegion(\"us-east-1\");\n final Path placeholder = new S3Touch...
{ "fields": [ { "declarator": "log = Logger.getLogger(S3VersionedObjectListService.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(S3VersionedObjectListService.class);", "type": "Logger", "var_name": "log" }, ...
{ "body": "@Override\n public AttributedList<Path> list(final Path directory, final ListProgressListener listener) throws BackgroundException {\n final ThreadPool pool = ThreadPoolFactory.get(\"list\", concurrency);\n try {\n final String prefix = this.createPrefix(directory);\n ...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_555
{ "fields": [], "file": "webdav/src/test/java/ch/cyberduck/core/dav/DAVSessionTest.java", "identifier": "DAVSessionTest", "interfaces": "", "superclass": "extends AbstractDAVTest" }
{ "body": "@Test(expected = ConnectionRefusedException.class)\n public void testConnectRefused() throws Exception {\n final Host host = new Host(new DAVSSLProtocol(), \"localhost\", 2121);\n final DAVSession session = new DAVSession(host,\n new CertificateStoreX509TrustManager(new Disabled...
{ "fields": [ { "declarator": "log = Logger.getLogger(DAVSession.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(DAVSession.class);", "type": "Logger", "var_name": "log" }, { "declarator": "redirect\n ...
{ "body": "@Override\n public void login(final Proxy proxy, final LoginCallback prompt, final CancelCallback cancel) throws BackgroundException {\n final CredentialsProvider provider = new BasicCredentialsProvider();\n if(preferences.getBoolean(\"webdav.ntlm.windows.authentication.enable\") && WinHtt...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1453
{ "fields": [], "file": "cli/src/test/java/ch/cyberduck/cli/TerminalLoginCallbackTest.java", "identifier": "TerminalLoginCallbackTest", "interfaces": "", "superclass": "" }
{ "body": "@Test(expected = LoginCanceledException.class)\n public void testWarn() throws Exception {\n new TerminalLoginCallback(new TerminalPromptReader() {\n @Override\n public boolean prompt(final String message) {\n return false;\n }\n }).warn(new ...
{ "fields": [ { "declarator": "console = new Console()", "modifier": "private final", "original_string": "private final Console console = new Console();", "type": "Console", "var_name": "console" }, { "declarator": "prompt", "modifier": "private final", "ori...
{ "body": "@Override\n public void warn(final Host bookmark, final String title, final String reason,\n final String defaultButton, final String cancelButton, final String preference) throws ConnectionCanceledException {\n console.printf(\"%n%s\", reason);\n if(!prompt.prompt(Stri...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_806
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/exception/BackgroundExceptionTest.java", "identifier": "BackgroundExceptionTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testGetMessage() {\n final BackgroundException e = new BackgroundException(new LoginCanceledException());\n e.setMessage(\"m\");\n assertEquals(\"m\", e.getMessage());\n }", "class_method_signature": "BackgroundExceptionTest.testGetMessage()", "constructor...
{ "fields": [ { "declarator": "serialVersionUID = -6114495291207129418L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = -6114495291207129418L;", "type": "long", "var_name": "serialVersionUID" }, { "declarator": "fil...
{ "body": "@Override\n public String getMessage() {\n return null == message ? LocaleFactory.localizedString(\"Unknown\") : message;\n }", "class_method_signature": "BackgroundException.getMessage()", "constructor": false, "full_signature": "@Override public String getMessage()", "identifier": "g...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1003
{ "fields": [], "file": "core/src/test/java/ch/cyberduck/core/transfer/upload/ResumeFilterTest.java", "identifier": "ResumeFilterTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testPrepare0() throws Exception {\n final ResumeFilter f = new ResumeFilter(new DisabledUploadSymlinkResolver(), new NullSession(new Host(new TestProtocol())),\n new UploadFilterOptions().withTemporary(true));\n final Path t = new Path(\"t\", EnumSet.of(P...
{ "fields": [ { "declarator": "log = Logger.getLogger(ResumeFilter.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(ResumeFilter.class);", "type": "Logger", "var_name": "log" }, { "declarator": "upload",...
{ "body": "@Override\n public TransferStatus prepare(final Path file, final Local local, final TransferStatus parent, final ProgressListener progress) throws BackgroundException {\n final TransferStatus status = super.prepare(file, local, parent, progress);\n if(file.isFile()) {\n if(paren...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_386
{ "fields": [], "file": "googledrive/src/test/java/ch/cyberduck/core/googledrive/DriveCopyFeatureTest.java", "identifier": "DriveCopyFeatureTest", "interfaces": "", "superclass": "extends AbstractDriveTest" }
{ "body": "@Test\n public void testCopyToExistingFile() throws Exception {\n final Path folder = new Path(DriveHomeFinderService.MYDRIVE_FOLDER, new AlphanumericRandomStringService().random(), EnumSet.of(Path.Type.directory));\n final DriveFileidProvider fileid = new DriveFileidProvider(session).with...
{ "fields": [ { "declarator": "session", "modifier": "private final", "original_string": "private final DriveSession session;", "type": "DriveSession", "var_name": "session" }, { "declarator": "fileid", "modifier": "private final", "original_string": "privat...
{ "body": "@Override\n public Path copy(final Path source, final Path target, final TransferStatus status, final ConnectionCallback callback) throws BackgroundException {\n try {\n final File copy = session.getClient().files().copy(fileid.getFileid(source, new DisabledListProgressListener()), new...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_1280
{ "fields": [], "file": "ssh/src/test/java/ch/cyberduck/core/sftp/SFTPListServiceTest.java", "identifier": "SFTPListServiceTest", "interfaces": "", "superclass": "extends AbstractSFTPTest" }
{ "body": "@Test\n public void testInvalidSymlinkTarget() throws Exception {\n final Path home = new SFTPHomeDirectoryService(session).find();\n final Path file = new Path(home, new AlphanumericRandomStringService().random(), EnumSet.of(Path.Type.file, Path.Type.symboliclink));\n final String ...
{ "fields": [ { "declarator": "log = Logger.getLogger(SFTPListService.class)", "modifier": "private static final", "original_string": "private static final Logger log = Logger.getLogger(SFTPListService.class);", "type": "Logger", "var_name": "log" }, { "declarator": "se...
{ "body": "@Override\n public AttributedList<Path> list(final Path directory, final ListProgressListener listener) throws BackgroundException {\n try {\n final AttributedList<Path> children = new AttributedList<Path>();\n final RemoteDirectory handle = session.sftp().openDir(directory....
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...
79564911_739
{ "fields": [], "file": "core/dylib/src/test/java/ch/cyberduck/core/local/WorkspaceIconServiceTest.java", "identifier": "WorkspaceIconServiceTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void testSetProgressFolder() throws Exception {\n final WorkspaceIconService s = new WorkspaceIconService();\n final Local file = new Local(PreferencesFactory.get().getProperty(\"tmp.dir\"),\n UUID.randomUUID().toString());\n new DefaultLocalDirectoryFe...
{ "fields": [], "file": "core/dylib/src/main/java/ch/cyberduck/core/local/WorkspaceIconService.java", "identifier": "WorkspaceIconService", "interfaces": "implements IconService", "methods": [ { "class_method_signature": "WorkspaceIconService.set(final Local file, final String image)", "constr...
{ "body": "protected boolean update(final Local file, final NSImage icon) {\n synchronized(NSWorkspace.class) {\n // Specify 0 if you want to generate icons in all available icon representation formats\n final NSWorkspace workspace = NSWorkspace.sharedWorkspace();\n if(workspac...
{ "created": "1/20/2017 2:16:34 PM +00:00", "fork": "False", "fork_count": null, "is_fork": null, "language": null, "license": "licensed", "repo_id": 79564911, "size": null, "stargazer_count": null, "stars": 706, "updates": "2020-01-27T14:40:15+00:00", "url": "https://github.com/iterate-ch/cyber...