ome.services.fulltext.bridges
Class ProjectWithImageNameBridge
java.lang.Object
ome.services.fulltext.BridgeHelper
ome.services.fulltext.bridges.ProjectWithImageNameBridge
- All Implemented Interfaces:
- org.hibernate.search.bridge.FieldBridge, org.springframework.context.ApplicationEventPublisherAware
public class ProjectWithImageNameBridge
- extends BridgeHelper
Example custom FieldBridge
implementation which parses all
Image
names from a Project
and inserts them into the index
for that Project
.
- Since:
- 3.0-Beta3
- Author:
- Josh Moore, josh at glencoesoftware.com
Method Summary |
void |
set(String name,
Object value,
Document document,
Field.Store store,
Field.Index index,
Float boost)
If the "value" argument is a Project , this
bridge gathers all images and adds them to the index
with a slightly reduced boost value. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ProjectWithImageNameBridge
public ProjectWithImageNameBridge()
set
public void set(String name,
Object value,
Document document,
Field.Store store,
Field.Index index,
Float boost)
- If the "value" argument is a
Project
, this
bridge
gathers all images and adds them to the index
with a slightly reduced boost value. The field name of the image name is
"image_name" but the values are also added to the
BridgeHelper.COMBINED
field via the
BridgeHelper.add(Document, String, String, org.apache.lucene.document.Field.Store, org.apache.lucene.document.Field.Index, Float)
method.
- Specified by:
set
in interface org.hibernate.search.bridge.FieldBridge
- Specified by:
set
in class BridgeHelper
OmeroJava Api
Version: Beta-4.1.1-r5927-b91
Copyright © 2009 The University of Dundee. All Rights Reserved.