Searched defs:file (Results 1 - 25 of 37) sorted by relevance

12

/lucene-3.6.0/lucene/contrib/demo/src/java/org/apache/lucene/demo/
H A DIndexFiles.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
130 * Indexes the given file using the given writer, or if a directory is given,
133 * NOTE: This method indexes one document per input file. This is slow. For good
134 * throughput, put multiple documents into your input file(s). An example of this is
140 * @param writer Writer to the index where the given file/dir info will be stored
141 * @param file The file to index, or the directory to recurse into to find files to index
144 static void indexDocs(IndexWriter writer, File file) argument
[all...]
/lucene-3.6.0/lucene/contrib/spellchecker/src/java/org/apache/lucene/search/spell/
H A DPlainTextDictionary.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
30 * Dictionary represented by a text file.
41 public PlainTextDictionary(File file) throws FileNotFoundException { argument
42 in = new BufferedReader(new FileReader(file));
/lucene-3.6.0/lucene/core/src/java/org/apache/lucene/util/
H A DCommandLineUtil.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
40 * @param file The file to be used as parameter constructor
43 public static FSDirectory newFSDirectory(String clazzName, File file) { argument
46 return newFSDirectory(clazz, file);
98 * @param file The file to be used as parameter constructor
105 public static FSDirectory newFSDirectory(Class<? extends FSDirectory> clazz, File file) argument
[all...]
H A DIOUtils.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
272 * @param file the file to open a reader on
274 * @return a reader to read the given file
276 public static Reader getDecodingReader(File file, Charset charSet) throws IOException { argument
280 stream = new FileInputStream(file);
303 * @return a reader to read the given file
/lucene-3.6.0/lucene/core/src/test/org/apache/lucene/index/
H A DTestIndexWriterOnJRECrash.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
90 + System.getProperty("file.separator")
92 + System.getProperty("file.separator")
124 * Recursively looks for indexes underneath <code>file</code>,
127 public boolean checkIndexes(File file) throws IOException { argument
128 if (file.isDirectory()) {
129 MockDirectoryWrapper dir = newFSDirectory(file);
133 System.err.println("Checking index: " + file);
[all...]
/lucene-3.6.0/lucene/backwards/src/test/org/apache/lucene/index/
H A DTestIndexWriterOnJRECrash.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
90 + System.getProperty("file.separator")
92 + System.getProperty("file.separator")
124 * Recursively looks for indexes underneath <code>file</code>,
127 public boolean checkIndexes(File file) throws IOException { argument
128 if (file.isDirectory()) {
129 MockDirectoryWrapper dir = newFSDirectory(file);
133 System.err.println("Checking index: " + file);
[all...]
/lucene-3.6.0/lucene/contrib/analyzers/stempel/src/test/org/egothor/stemmer/
H A DTestCompile.java11 license applies to a single file or document, the "Egothor developers"
12 are the people or entities mentioned as copyright holders in that file
15 the file CREDITS. This file can be found in the same location as this
120 private static void assertTrie(Trie trie, String file, boolean usefull, argument
123 new FileReader(file)));
/lucene-3.6.0/solr/core/src/test/org/apache/solr/handler/admin/
H A DCoreAdminHandlerTest.java3 * contributor license agreements. See the NOTICE file distributed with
5 * The ASF licenses this file to You under the Apache License, Version 2.0
6 * (the "License"); you may not use this file except in compliance with
87 // verify props are in persisted file
101 public void assertXmlFile(final File file, String... xpath) argument
105 String xml = FileUtils.readFileToString(file, "UTF-8");
108 String msg = "File XPath failure: file=" + file.getPath() + " xpath="
/lucene-3.6.0/solr/solrj/src/java/org/apache/solr/client/solrj/request/
H A DContentStreamUpdateRequest.java4 * contributor license agreements. See the NOTICE file distributed with
6 * The ASF licenses this file to You under the Apache License, Version 2.0
7 * (the "License"); you may not use this file except in compliance with
58 * @param file The File to add.
59 * @throws IOException if there was an error with the file.
64 public void addFile(File file) throws IOException { argument
65 addContentStream(new ContentStreamBase.FileStream(file));
/lucene-3.6.0/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/
H A DFileDataSource.java3 * contributor license agreements. See the NOTICE file distributed with
5 * The ASF licenses this file to You under the Apache License, Version 2.0
6 * (the "License"); you may not use this file except in compliance with
32 * The file is read with the default platform encoding. It can be overriden by
56 * The encoding using which the given file should be read
71 * Returns a reader for the given file.
74 * If the given file is not absolute, we try to construct an absolute path
76 * tried. If file is not found a RuntimeException is thrown.
97 File file = file0;
99 if (!file
126 openStream(File file) argument
[all...]
/lucene-3.6.0/lucene/contrib/benchmark/src/java/org/apache/lucene/benchmark/byTask/utils/
H A DStreamUtils.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
84 * Returns an {@link InputStream} over the requested file. This method
86 * based on the file name (e.g., if it ends with .bz2 or .bzip, return a
89 public static InputStream inputStream(File file) throws IOException { argument
92 InputStream in = new BufferedInputStream(new FileInputStream(file), BUFFER_SIZE);
93 return fileType(file).inputStream(in);
96 /** Return the type of the file, or null if unknown */
97 private static Type fileType(File file) { argument
111 outputStream(File file) argument
[all...]
/lucene-3.6.0/solr/core/src/test/org/apache/solr/handler/component/
H A DQueryElevationComponentTest.java3 * contributor license agreements. See the NOTICE file distributed with
5 * The ASF licenses this file to You under the Apache License, Version 2.0
6 * (the "License"); you may not use this file except in compliance with
315 // write a test file to boost some docs
316 private void writeFile( File file, String query, String ... ids ) throws Exception argument
318 PrintWriter out = new PrintWriter( new FileOutputStream( file ) );
330 log.info( "OUT:"+file.getAbsolutePath() );
355 // now change the file
/lucene-3.6.0/lucene/contrib/misc/src/java/org/apache/lucene/store/
H A DWindowsDirectory.java5 * contributor license agreements. See the NOTICE file distributed with this
7 * licenses this file to You under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance with the License.
83 public WindowsIndexInput(File file, int bufferSize) throws IOException { argument
84 super("WindowsIndexInput(path=\"" + file.getPath() + "\")", bufferSize);
85 fd = WindowsDirectory.open(file.getPath());
132 /** Opens a handle to a file. */
135 /** Reads data from a file at pos into bytes */
138 /** Closes a handle to a file */
141 /** Returns the length of a file */
[all...]
/lucene-3.6.0/lucene/core/src/java/org/apache/lucene/index/
H A DCompoundFileWriter.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
31 * Combines multiple files into a single compound file.
32 * The file format:<br>
42 * fileCount entries with the raw data of the corresponding file</li>
46 * file. The {directory} that follows has that many entries. Each directory entry
47 * contains a long pointer to the start of this file's data section, and a String
48 * with that file's name.
55 /** source file */
56 String file; field in class:CompoundFileWriter.FileEntry
124 addFile(String file) argument
132 addFile(String file, Directory dir) argument
[all...]
/lucene-3.6.0/solr/core/src/test/org/apache/solr/handler/
H A DTestCSVLoader.java3 * contributor license agreements. See the NOTICE file distributed with
5 * The ASF licenses this file to You under the Apache License, Version 2.0
6 * (the "License"); you may not use this file except in compliance with
42 File file = new File(filename); field in class:TestCSVLoader
77 file.delete();
88 // TODO: stop using locally defined streams once stream.file and
99 loadLocal("stream.file",filename);
109 loadLocal("stream.file",filename,"commit","false");
118 loadLocal("stream.file",filename,"commit","true");
127 loadLocal("stream.file",filenam
[all...]
/lucene-3.6.0/solr/solrj/src/java/org/apache/solr/common/util/
H A DContentStreamBase.java3 * contributor license agreements. See the NOTICE file distributed with
5 * The ASF licenses this file to You under the Apache License, Version 2.0
6 * (the "License"); you may not use this file except in compliance with
96 private final File file; field in class:ContentStreamBase.FileStream
99 file = f;
102 name = file.getName();
103 size = file.length();
104 sourceInfo = file.toURI().toString();
108 return new FileInputStream( file );
113 * use a file reade
[all...]
/lucene-3.6.0/lucene/core/src/java/org/apache/lucene/store/
H A DRAMInputStream.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
29 private RAMFile file; field in class:RAMInputStream
47 file = f;
48 length = file.length;
97 if (currentBufferIndex >= file.numBuffers()) {
98 // end of file reached, no more buffers left
107 currentBuffer = file.getBuffer(currentBufferIndex);
H A DRAMOutputStream.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
30 private RAMFile file; field in class:RAMOutputStream
45 file = f;
56 final long end = file.length;
65 out.writeBytes(file.getBuffer(buffer++), length);
70 /** Resets this to an empty file. */
77 file.setLength(0);
87 // set the file lengt
[all...]
H A DSimpleFSDirectory.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
29 * read from the same file. It's usually better to use
53 /** Creates an IndexInput for the file with the given name. */
64 // remember if the file is open, so that we don't try to close it
70 public Descriptor(File file, String mode) throws IOException { argument
71 super(file, mode);
85 protected final Descriptor file; field in class:SimpleFSDirectory.SimpleFSIndexInput
98 file
[all...]
H A DFSDirectory.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
40 * files in the file system. There are currently three core
50 * same file.
54 * synchronization when reading from the same file.
77 * is unable to close the underlying OS file handle. Only when
79 * quite some time later, will the file handle be closed.
128 private static File getCanonicalPath(File file) throws IOException { argument
129 return new File(file
435 private final RandomAccessFile file; field in class:FSDirectory.FSIndexOutput
[all...]
/lucene-3.6.0/lucene/contrib/benchmark/src/java/org/apache/lucene/benchmark/byTask/feeds/
H A DLineDocSource.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
35 * {@link org.apache.lucene.document.Document} from a single file. This saves IO
37 * new file for every document.<br>
45 * <li>docs.file=&lt;path to the file&gt;
57 * @param header header line found in the input file, or null if none
101 * the header - any header - of the lines file.
172 private File file; field in class:LineDocSource
[all...]
/lucene-3.6.0/lucene/contrib/benchmark/src/test/org/apache/lucene/benchmark/byTask/feeds/
H A DLineDocSourceTest.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
52 private void createBZ2LineFile(File file, boolean addHeader) throws Exception { argument
53 OutputStream out = new FileOutputStream(file);
90 private void createRegularLineFile(File file, boolean addHeader) throws Exception { argument
91 OutputStream out = new FileOutputStream(file);
97 private void createRegularLineFileWithMoreFields(File file, String...extraFields) throws Exception { argument
98 OutputStream out = new FileOutputStream(file);
108 private void doIndexAndSearchTest(File file, Clas argument
114 doIndexAndSearchTestWithRepeats(File file, Class<? extends LineParser> lineParserClass, int numAdds, String storedField) argument
[all...]
/lucene-3.6.0/lucene/contrib/benchmark/src/test/org/apache/lucene/benchmark/byTask/tasks/
H A DWriteLineDocTaskTest.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
139 private PerfRunData createPerfRunData(File file, argument
144 props.setProperty("line.file.out", file.getAbsolutePath());
157 private void doReadTest(File file, Type fileType, String expTitle, argument
159 InputStream in = new FileInputStream(file);
170 assertFalse("Unknown file type!",true); //fail, should not happen
200 File file
[all...]
/lucene-3.6.0/lucene/contrib/facet/src/java/org/apache/lucene/facet/taxonomy/writercache/cl2o/
H A DCompactLabelToOrdinal.java17 * contributor license agreements. See the NOTICE file distributed with
19 * The ASF licenses this file to You under the Apache License, Version 2.0
20 * (the "License"); you may not use this file except in compliance with
449 * Opens the file and reloads the CompactLabelToOrdinal. The file it expects
452 static CompactLabelToOrdinal open(File file, float loadFactor, argument
455 * Part of the file is the labelRepository, which needs to be rehashed
457 * can't just store these off in the file as well, but in keeping with
467 new FileInputStream(file)));
493 // that array offsets will work). Since the initial file i
540 flush(File file) argument
[all...]
/lucene-3.6.0/lucene/contrib/spellchecker/src/java/org/apache/lucene/search/suggest/fst/
H A DSort.java5 * contributor license agreements. See the NOTICE file distributed with
7 * The ASF licenses this file to You under the Apache License, Version 2.0
8 * (the "License"); you may not use this file except in compliance with
195 for (File file : merges) {
196 file.delete();
221 for (File file : merges) {
222 file.delete();
248 * Copies one file to another.
250 private static void copy(File file, File output) throws IOException { argument
256 is = new FileInputStream(file);
381 ByteSequencesWriter(File file) argument
426 ByteSequencesReader(File file) argument
[all...]

Completed in 6972 milliseconds

12