本文整理汇总了Java中org.apache.lucene.util.AttributeReflector.reflect方法的典型用法代码示例。如果您正苦于以下问题:Java AttributeReflector.reflect方法的具体用法?Java AttributeReflector.reflect怎么用?Java AttributeReflector.reflect使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.apache.lucene.util.AttributeReflector
的用法示例。
在下文中一共展示了AttributeReflector.reflect方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
super.reflectWith(reflector);
reflector.reflect(OffsetAttribute.class, "startOffset", startOffset);
reflector.reflect(OffsetAttribute.class, "endOffset", endOffset);
reflector.reflect(PositionIncrementAttribute.class, "positionIncrement", positionIncrement);
reflector.reflect(PositionLengthAttribute.class, "positionLength", positionLength);
reflector.reflect(TypeAttribute.class, "type", type);
}
示例2: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
fillBytesRef();
reflector.reflect(TermToBytesRefAttribute.class, "bytes", bytes.toBytesRef());
reflector.reflect(NumericTermAttribute.class, "shift", shift);
reflector.reflect(NumericTermAttribute.class, "rawValue", getRawValue());
reflector.reflect(NumericTermAttribute.class, "valueSize", valueSize);
}
示例3: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
super.reflectWith(reflector);
reflector.reflect(OffsetAttribute.class, "startOffset", startOffset);
reflector.reflect(OffsetAttribute.class, "endOffset", endOffset);
reflector.reflect(PositionIncrementAttribute.class, "positionIncrement", positionIncrement);
reflector.reflect(PayloadAttribute.class, "payload", payload);
reflector.reflect(FlagsAttribute.class, "flags", flags);
reflector.reflect(TypeAttribute.class, "type", type);
}
示例4: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
reflector.reflect(StemmingBufferAttribute.class, "stemmedToken", stemmedToken);
reflector.reflect(StemmingBufferAttribute.class, "stemmedTokenLength", stemmedTokenLength);
reflector.reflect(StemmingBufferAttribute.class, "originalToken", originalToken);
reflector.reflect(StemmingBufferAttribute.class, "originalTokenLength", originalTokenLength);
}
示例5: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
String reading = getReading();
String readingEN = reading == null ? null : ToStringUtil.getRomanization(reading);
String pronunciation = getPronunciation();
String pronunciationEN = pronunciation == null ? null : ToStringUtil.getRomanization(pronunciation);
reflector.reflect(ReadingAttribute.class, "reading", reading);
reflector.reflect(ReadingAttribute.class, "reading (en)", readingEN);
reflector.reflect(ReadingAttribute.class, "pronunciation", pronunciation);
reflector.reflect(ReadingAttribute.class, "pronunciation (en)", pronunciationEN);
}
示例6: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
String partOfSpeech = getPartOfSpeech();
String partOfSpeechEN = partOfSpeech == null ? null : ToStringUtil.getPOSTranslation(partOfSpeech);
reflector.reflect(PartOfSpeechAttribute.class, "partOfSpeech", partOfSpeech);
reflector.reflect(PartOfSpeechAttribute.class, "partOfSpeech (en)", partOfSpeechEN);
}
示例7: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
String type = getInflectionType();
String typeEN = type == null ? null : ToStringUtil.getInflectionTypeTranslation(type);
reflector.reflect(InflectionAttribute.class, "inflectionType", type);
reflector.reflect(InflectionAttribute.class, "inflectionType (en)", typeEN);
String form = getInflectionForm();
String formEN = form == null ? null : ToStringUtil.getInflectedFormTranslation(form);
reflector.reflect(InflectionAttribute.class, "inflectionForm", form);
reflector.reflect(InflectionAttribute.class, "inflectionForm (en)", formEN);
}
示例8: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
// when wordbreaking CJK, we use the 15924 code Japanese (Han+Hiragana+Katakana) to
// mark runs of Chinese/Japanese. our use is correct (as for chinese Han is a subset),
// but this is just to help prevent confusion.
String name = code == UScript.JAPANESE ? "Chinese/Japanese" : getName();
reflector.reflect(ScriptAttribute.class, "script", name);
}
示例9: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
fillBytesRef();
reflector.reflect(TermToBytesRefAttribute.class, "bytes", BytesRef.deepCopyOf(bytes));
reflector.reflect(NumericTermAttribute.class, "shift", shift);
reflector.reflect(NumericTermAttribute.class, "rawValue", getRawValue());
reflector.reflect(NumericTermAttribute.class, "valueSize", valueSize);
}
示例10: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
final List<String> pronunciations = getPronunciations();
List<String> enPronunciations = null;
if (pronunciations != null) {
final String[] p = new String[pronunciations.size()];
int i = 0;
for (String kana : pronunciations) {
p[i++] = ToStringUtil.getRomanization(kana);
}
enPronunciations = Arrays.asList(p);
}
reflector.reflect(PronunciationsAttribute.class, "pronunciations", pronunciations);
reflector.reflect(PronunciationsAttribute.class, "pronunciations (en)", enPronunciations);
}
示例11: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
String conjugationalForm = getConjugationalForm();
String conjugationalType = getConjugationalType();
String enForm = conjugationalForm == null ? null : ToStringUtil.getConjFormTranslation(conjugationalForm);
String enType = conjugationalType == null ? null : ToStringUtil.getConjTypeTranslation(conjugationalType);
reflector.reflect(ConjugationAttribute.class, "conjugationalForm", conjugationalForm);
reflector.reflect(ConjugationAttribute.class, "conjugationalForm (en)", enForm);
reflector.reflect(ConjugationAttribute.class, "conjugationalType", conjugationalType);
reflector.reflect(ConjugationAttribute.class, "conjugationalType (en)", enType);
}
示例12: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
reflector.reflect(CharTermAttribute.class, "term", toString());
fillBytesRef();
reflector.reflect(TermToBytesRefAttribute.class, "bytes", bytes.toBytesRef());
}
示例13: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
super.reflectWith(reflector);
reflector.reflect(FlagsAttribute.class, "flags", flags);
reflector.reflect(PayloadAttribute.class, "payload", payload);
}
示例14: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
reflector.reflect(KeywordAttribute.class, "isExact", isExact);
reflector.reflect(KeywordAttribute.class, "type", type);
}
示例15: reflectWith
import org.apache.lucene.util.AttributeReflector; //导入方法依赖的package包/类
@Override
public void reflectWith(AttributeReflector reflector) {
reflector.reflect(PartOfSpeechAttribute.class, "partOfSpeech", partOfSpeech());
}