src/PredFinder/elf/ElfIndividual.cpp
/**
 * Construct an ElfIndividual from a specified type and value string.
 * Intended only for use with literal values (integers, dates, etc.).
 * Always normalizes the value string according to type if possible.
 *
 * @param type_string The string URI of the type of the new value.
 * @param value The string value itself.
 * @param text An optional text evidence for the new value.
 * @param start An optional start offset for the text evidence.
 * @param end An optional end offset for the text evidence.
 *
 * @author nward@bbn.com
 * @date 2011.05.09
 **/
Construct an ElfIndividual from a specified type and value string.
Intended only for use with literal values (integers, dates, etc.).
Always normalizes the value string according to type if possible.

@param type_string The string URI of the type of the new value.
@param value The string value itself.
@param text An optional text evidence for the new value.
@param start An optional start offset for the text evidence.
@param end An optional end offset for the text evidence.


Construct an ElfIndividual from a specified type and value string . Intended only for use with literal values ( integers dates etc . ) . Always normalizes the value string according to type if possible . @param type_string The string URI of the type of the new value . @param value The string value itself . @param text An optional text evidence for the new value . @param start An optional start offset for the text evidence . @param end An optional end offset for the text evidence .
ElfIndividual::ElfIndividual(const std::wstring & type_string, const std::wstring & value, const std::wstring & text, EDTOffset start, EDTOffset end) {
	initialize();
	_value = get_text_according_to_type(type_string, value);
	_is_value = true;
	_value_mention_id = -1;
	boost::hash<std::wstring> string_hasher;
	std::wstringstream value_uri;
	value_uri << L"bbn:value-" << string_hasher(_value);
	_generated_uri = value_uri.str();
	_name_or_desc = boost::make_shared<ElfDescriptor>(_value, 1.0, text, start, end);
	_types.insert(boost::make_shared<ElfType>(type_string, text, start, end));
}
ElfIndividual :: ElfIndividual ( const std :: wstring & type_string , const std :: wstring & value , const std :: wstring & text , EDTOffset start , EDTOffset end ) { initialize ( ) ; _value = get_text_according_to_type ( type_string , value ) ; _is_value = true ; _value_mention_id = -1 ; boost :: hash < std :: wstring > string_hasher ; std :: wstringstream value_uri ; value_uri << L" " << string_hasher ( _value ) ; _generated_uri = value_uri . str ( ) ; _name_or_desc = boost :: make_shared < ElfDescriptor > ( _value , 1.0 , text , start , end ) ; _types . insert ( boost :: make_shared < ElfType > ( type_string , text , start , end ) ) ; }
Construct an ElfIndividual from a specified type and value string.
Construct an ElfIndividual from a specified type and value string .
// Set all IDs to empty
 // Filter the value text
 //   We don't need a doc_theory here because that only applies to a rare case for NFLTeam lookup
 // No associated Serif ValueMention, generate a placeholder URI
 // Add the specified type and desc using the value mention text
