Code example for FileInputStream

Methods: close

0
            final long elderCheck = d.getTime() - (KEEP_LENGTH);
            if (f.lastModified() < elderCheck) {
                shouldRefresh = true;
            } else { 
                try { 
                    final FileInputStream in = new FileInputStream(f);
                    repo = GsonUtils.fromJson(new BufferedReader(
                            new InputStreamReader(in)), Repository.class);
                    in.close();
                    return repo;
                } catch (Exception e) {
                    shouldRefresh = true;
                } 
            } 
        } else { 
            shouldRefresh = true;
        } 
        if (shouldRefresh || forceUpdate) {
            try { 
                final RepositoryService rs = new RepositoryService(context.getGHClient());
Stop searching for code, let great code find you!  Add Codota to your java IDE