Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 7 of 7 for GetPath (0.18 sec)

  1. src/test/java/org/codelibs/core/io/FileUtilTest.java

        }
    
        /**
         * @throws Exception
         */
        @Test
        public void testReadUTF8() throws Exception {
            assertThat(FileUtil.readUTF8(getPath("hoge_utf8.txt")), is("あ"));
        }
    
        private String getPath(final String fileName) {
            return getClass().getName().replace('.', '/').replaceFirst(getClass().getSimpleName(), fileName);
        }
    
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 1.6K bytes
    - Viewed (0)
  2. src/test/java/org/codelibs/core/io/ResourceUtilTest.java

                ResourceUtil.getResource("hoge", "xml");
                fail("2");
            } catch (final ResourceNotFoundRuntimeException e) {
                System.out.println(e);
                assertEquals("3", "hoge.xml", e.getPath());
            }
            System.out.println(ResourceUtil.getResource("."));
        }
    
        /**
         * @throws Exception
         */
        public void testGetResourceAsStreamNoException() throws Exception {
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 4.3K bytes
    - Viewed (0)
  3. src/main/java/org/codelibs/core/jar/JarFileUtil.java

         */
        public static String toJarFilePath(final URL jarUrl) {
            assertArgumentNotNull("jarUrl", jarUrl);
    
            final URL nestedUrl = URLUtil.create(jarUrl.getPath());
            final String nestedUrlPath = nestedUrl.getPath();
            final int pos = nestedUrlPath.lastIndexOf('!');
            final String jarFilePath = nestedUrlPath.substring(0, pos);
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 5.4K bytes
    - Viewed (0)
  4. src/main/java/org/codelibs/core/zip/ZipFileUtil.java

         * @return URLで指定されたZipファイルのパス
         */
        public static String toZipFilePath(final URL zipUrl) {
            assertArgumentNotNull("zipUrl", zipUrl);
    
            final String urlString = zipUrl.getPath();
            final int pos = urlString.lastIndexOf('!');
            final String zipFilePath = urlString.substring(0, pos);
            final File zipFile = new File(URLUtil.decode(zipFilePath, "UTF8"));
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 5.1K bytes
    - Viewed (0)
  5. src/main/java/org/codelibs/core/io/TraversalUtil.java

            addTraverserFactory("code-source",
                    (url, rootPackage, rootDir) -> new JarFileTraverser(URLUtil.create("jar:file:" + url.getPath()), rootPackage, rootDir));
            addTraverserFactory("vfszip", VfsZipTraverser::new);
        }
    
        /**
         * {@link TraverserFactory}を追加します。
         *
         * @param protocol
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 19.5K bytes
    - Viewed (0)
  6. src/main/java/org/codelibs/core/exception/ResourceNotFoundRuntimeException.java

            super("ECL0055", asArray(path));
            this.path = path;
        }
    
        /**
         * パスを返します。
         *
         * @return パス
         */
        public String getPath() {
            return path;
        }
    
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 1.4K bytes
    - Viewed (0)
  7. src/main/java/org/codelibs/core/net/URLUtil.java

         */
        public static File toFile(final URL fileUrl) {
            assertArgumentNotNull("fileUrl", fileUrl);
    
            try {
                final String path = URLDecoder.decode(fileUrl.getPath(), "UTF-8");
                return new File(path).getAbsoluteFile();
            } catch (final Exception e) {
                throw new ClRuntimeException("ECL0091", asArray(fileUrl), e);
            }
        }
    
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 7.3K bytes
    - Viewed (0)
Back to top