Plucene::Index::TermInfo - Information on an index term


Plucene documentation Contained in the Plucene distribution.

Index


Code Index:

NAME

Top

Plucene::Index::TermInfo - Information on an index term

SYNOPSIS

Top

	my $term_info = Plucene::Index::TermInfo->new({
			doc_freq     => $doc_freq,
			freq_pointer => $freq_pointer,
			prox_pointer => $prox_pointer,
	});

DESCRIPTION

Top

This class holds information about an index term.

METHODS

Top

doc_freq / freq_pointer / prox_pointer

Get / set term info.

copy_in / clone

	$term_info1->copy_in($term_info2);

	my $term_info1 = $term_info2->clone;

These will make $term_info1 be the same as $term_info2.


Plucene documentation Contained in the Plucene distribution.
package Plucene::Index::TermInfo;

use strict;
use warnings;

use Carp;

use base 'Class::Accessor::Fast';

__PACKAGE__->mk_accessors(qw( doc_freq freq_pointer prox_pointer ));

sub copy_in {
	my ($self, $other) = @_;
	%$self = %$other;
	return $self;
}

sub clone {
	my $self = shift;
	return bless {%$self} => ref $self;
}

1;