Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 66 for try (0.31 sec)

  1. src/main/java/org/codelibs/core/sql/PreparedStatementUtil.java

         *             {@link SQLException}が発生した場合
         */
        public static ResultSet executeQuery(final PreparedStatement ps) throws SQLRuntimeException {
            assertArgumentNotNull("ps", ps);
    
            try {
                return ps.executeQuery();
            } catch (final SQLException ex) {
                throw new SQLRuntimeException(ex);
            }
        }
    
        /**
         * 更新を実行します。
         *
         * @param ps
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 3.9K bytes
    - Viewed (0)
  2. src/main/java/org/codelibs/core/xml/DocumentBuilderFactoryUtil.java

        }
    
        public static DocumentBuilderFactory newInstance(final boolean external) {
            final DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
            if (!external) {
                try {
                    factory.setAttribute(XMLConstants.ACCESS_EXTERNAL_DTD, "");
                    factory.setAttribute(XMLConstants.ACCESS_EXTERNAL_SCHEMA, "");
                } catch (final Exception e) {
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 2.6K bytes
    - Viewed (0)
  3. src/main/java/org/codelibs/core/zip/ZipInputStreamUtil.java

         * @return {@link ZipEntry}
         * @see ZipInputStream#getNextEntry()
         */
        public static ZipEntry getNextEntry(final ZipInputStream zis) {
            assertArgumentNotNull("zis", zis);
    
            try {
                return zis.getNextEntry();
            } catch (final IOException e) {
                throw new IORuntimeException(e);
            }
        }
    
        /**
         * {@link ZipInputStream#reset()}の例外処理をラップするメソッドです。
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 2.9K bytes
    - Viewed (0)
  4. src/main/java/org/codelibs/core/beans/impl/PropertyDescImpl.java

        public void setValue(final Object target, final Object value) {
            assertArgumentNotNull("target", target);
    
            try {
                final Object convertedValue = convertIfNeed(value);
                assertState(writable, propertyName + " is not writable.");
                if (hasWriteMethod()) {
                    try {
                        MethodUtil.invoke(writeMethod, target, convertedValue);
                    } catch (final Throwable t) {
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 15.3K bytes
    - Viewed (0)
  5. src/main/java/org/codelibs/core/net/URLUtil.java

         *            URL。{@literal null}であってはいけません
         * @return URLが表すリソースを読み込むための{@link InputStream}
         */
        public static InputStream openStream(final URL url) {
            assertArgumentNotNull("url", url);
    
            try {
                final URLConnection connection = url.openConnection();
                connection.setUseCaches(false);
                return connection.getInputStream();
            } catch (final IOException 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)
  6. src/main/java/org/codelibs/core/io/PropertiesUtil.java

         */
        public static void load(final Properties props, final InputStream in) {
            assertArgumentNotNull("props", props);
            assertArgumentNotNull("in", in);
    
            try {
                props.load(in);
            } catch (final IOException e) {
                throw new IORuntimeException(e);
            }
        }
    
        /**
         * {@link Properties#load(Reader)}の例外処理をラップします。
         * <p>
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 8.9K bytes
    - Viewed (0)
  7. src/main/java/org/codelibs/core/stream/StreamUtil.java

                this.supplier = supplier;
            }
    
            public void of(final Consumer<Stream<T>> stream) {
                try (Stream<T> s = supplier.get()) {
                    stream.accept(s);
                }
            }
    
            public <R> R get(final Function<Stream<T>, R> stream) {
                try (Stream<T> s = supplier.get()) {
                    return stream.apply(s);
                }
            }
        }
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 2K bytes
    - Viewed (0)
  8. src/test/java/org/codelibs/core/io/InputStreamUtilTest.java

        /**
         * @throws Exception
         */
        public void testGetBytes() throws Exception {
            final InputStream is = ResourceUtil.getResourceAsStream(StringUtil.replace(getClass().getName(), ".", "/") + ".class");
            try {
                assertNotNull("1", InputStreamUtil.getBytes(is));
            } finally {
                is.close();
            }
        }
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 1.2K bytes
    - Viewed (0)
  9. src/main/java/org/codelibs/core/misc/DynamicProperties.java

            FileOutputStream fos = null;
            try {
                fos = new FileOutputStream(propertiesFile);
                properties.store(fos, propertiesFile.getName());
            } catch (final IOException e) {
                throw new FileAccessException("ECL0112", new Object[] { propertiesFile.getAbsolutePath() }, e);
            } finally {
                if (fos != null) {
                    try {
                        fos.close();
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 9.6K bytes
    - Viewed (0)
  10. src/main/java/org/codelibs/core/sql/DriverManagerUtil.java

         *
         * @param driver
         *            登録するJDBCドライバ。{@literal null}であってはいけません
         */
        public static void registerDriver(final Driver driver) {
            assertArgumentNotNull("driver", driver);
    
            try {
                DriverManager.registerDriver(driver);
            } catch (final SQLException e) {
                throw new SQLRuntimeException(e);
            }
        }
    
        /**
         * JDBCドライバを登録解除します。
         *
    Java
    - Registered: Fri May 03 20:58:11 GMT 2024
    - Last Modified: Thu Mar 07 01:59:08 GMT 2024
    - 3.3K bytes
    - Viewed (0)
Back to top