dragon.nlp.extract
Class AbstractDualConceptExtractor

java.lang.Object
  |
  +--dragon.nlp.extract.AbstractDualConceptExtractor
All Implemented Interfaces:
DualConceptExtractor

public abstract class AbstractDualConceptExtractor
extends java.lang.Object
implements DualConceptExtractor

Dual concept extractor for dual indexing

Copyright: Copyright (c) 2005

Company: IST, Drexel University

Version:
1.0
Author:
Davis Zhou

Field Summary
protected  java.util.ArrayList firstConceptList
           
protected  DocumentParser parser
           
protected  java.util.ArrayList secondConceptList
           
 
Constructor Summary
AbstractDualConceptExtractor()
           
 
Method Summary
 boolean extractFromDoc(Article article)
          Extracts concepts from a semi-structured article
 boolean extractFromDoc(java.lang.String doc)
          Extracts concepts from a raw document
protected  java.lang.String getArticleContent(Article article)
           
 DocumentParser getDocumentParser()
          Gets document parser.
 java.util.ArrayList getFirstConceptList()
          Gets the first set of concepts extracted before
 java.util.ArrayList getSecondConceptList()
          Gets the second set of concepts extracted before
 void initDocExtraction()
          It is required to call this method before one calls extractFromDoc method.
 boolean isExtractionMerged()
           
 void setDocumentParser(DocumentParser parser)
          Sets the document parser for the concept extractor.
 boolean supportConceptEntry()
          Tests if the extracted concept has an entry ID.
 boolean supportConceptName()
          Tests if the extracted concept has a name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface dragon.nlp.extract.DualConceptExtractor
extractFromDoc, extractFromSentence
 

Field Detail

firstConceptList

protected java.util.ArrayList firstConceptList

secondConceptList

protected java.util.ArrayList secondConceptList

parser

protected DocumentParser parser
Constructor Detail

AbstractDualConceptExtractor

public AbstractDualConceptExtractor()
Method Detail

extractFromDoc

public boolean extractFromDoc(Article article)
Description copied from interface: DualConceptExtractor
Extracts concepts from a semi-structured article

Specified by:
extractFromDoc in interface DualConceptExtractor
Parameters:
article - a semi-structured article for extraction
Returns:
true if extracted successfully

extractFromDoc

public boolean extractFromDoc(java.lang.String doc)
Description copied from interface: DualConceptExtractor
Extracts concepts from a raw document

Specified by:
extractFromDoc in interface DualConceptExtractor
Parameters:
doc - a raw document for extraction
Returns:
true if extracted successfully

getFirstConceptList

public java.util.ArrayList getFirstConceptList()
Description copied from interface: DualConceptExtractor
Gets the first set of concepts extracted before

Specified by:
getFirstConceptList in interface DualConceptExtractor
Returns:
the first set of concepts extracted before

getSecondConceptList

public java.util.ArrayList getSecondConceptList()
Description copied from interface: DualConceptExtractor
Gets the second set of concepts extracted before

Specified by:
getSecondConceptList in interface DualConceptExtractor
Returns:
the second set of concepts extracted before

isExtractionMerged

public boolean isExtractionMerged()

supportConceptName

public boolean supportConceptName()
Description copied from interface: DualConceptExtractor
Tests if the extracted concept has a name.

Specified by:
supportConceptName in interface DualConceptExtractor
Returns:
true or false

supportConceptEntry

public boolean supportConceptEntry()
Description copied from interface: DualConceptExtractor
Tests if the extracted concept has an entry ID.

Specified by:
supportConceptEntry in interface DualConceptExtractor
Returns:
true or false

initDocExtraction

public void initDocExtraction()
Description copied from interface: DualConceptExtractor
It is required to call this method before one calls extractFromDoc method.

Specified by:
initDocExtraction in interface DualConceptExtractor

getArticleContent

protected java.lang.String getArticleContent(Article article)

getDocumentParser

public DocumentParser getDocumentParser()
Description copied from interface: DualConceptExtractor
Gets document parser.

Specified by:
getDocumentParser in interface DualConceptExtractor
Returns:
the document parser.

setDocumentParser

public void setDocumentParser(DocumentParser parser)
Description copied from interface: DualConceptExtractor
Sets the document parser for the concept extractor.

Specified by:
setDocumentParser in interface DualConceptExtractor
Parameters:
parser - document parser