Documentation of 'ca.pfv.spmf.algorithms.sequentialpatterns.clospan_AGP.items.Itemset' Java class
Itemset
ca.pfv.spmf.algorithms.sequentialpatterns.clospan_AGP.items

Class Itemset



  • public final class Itemset
    extends java.lang.Object
    This class represents an itemset from a sequence. The itemset consists of a list of items and an timestamp that denotes when the itemset occurs. An itemset with timestamp is also called "transaction" Copyright Antonio Gomariz Peñalver 2013 This file is part of the SPMF DATA MINING SOFTWARE (http://www.philippe-fournier-viger.com/spmf). SPMF is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. SPMF is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with SPMF. If not, see .
    • Constructor Summary

      Constructors 
      Constructor and Description
      Itemset()
      Standard Itemset constructor
      Itemset(java.util.Collection<Item> collection, long timestamp)
      Constructor of an itemset from a collection of items and the timestamp associated with the itemset.
      Itemset(Item[] collection, long timestamp)
      Constructor of an itemset from an array of items and the timestamp associated with the itemset.
      Itemset(Item item, long timestamp)
      Constructor of an itemset from an item and the timestamp.
      Itemset(Itemset itemset, int beginning)
      Constructor of an itemset from an itemset and the beginning.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void addItem(int i, Item value)
      It adds an item to the itemset.
      void addItem(Item value)
      It adds an item to the itemset.
      Itemset cloneItemSet()
      It clones the itemset.
      boolean equals(java.lang.Object o)
      Check if this itemset is equal to another.
      Item get(int index)
      Get the item from the specified position.
      int getBeginning() 
      java.util.List<Item> getItems()
      It returns the items that compose the itemset.
      long getTimestamp() 
      int hashCode() 
      Item removeItem(int i)
      It removes the item which appears in the specified index.
      void removeItem(Item value)
      It removes the specified item.
      void setBeginning(int inicio) 
      void setTimestamp(long timestamp) 
      int size()
      It returns the number of items that compose the itemset.
      java.lang.String toString()
      Get a string representation of the itemset.
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • Itemset

        public Itemset(Item item,
                       long timestamp)
        Constructor of an itemset from an item and the timestamp.
        Parameters:
        item - the item that compose the itemset.
        timestamp - the timestamp associated with the itemset.
      • Itemset

        public Itemset(Itemset itemset,
                       int beginning)
        Constructor of an itemset from an itemset and the beginning.
        Parameters:
        itemset - the items that compose the itemset.
      • Itemset

        public Itemset(java.util.Collection<Item> collection,
                       long timestamp)
        Constructor of an itemset from a collection of items and the timestamp associated with the itemset.
        Parameters:
        collection - Items that compose the itemset.
        timestamp - the timestamp associated with the itemset
      • Itemset

        public Itemset(Item[] collection,
                       long timestamp)
        Constructor of an itemset from an array of items and the timestamp associated with the itemset.
        Parameters:
        collection - Items that compose the itemset.
        timestamp - the timestamp associated with the itemset
      • Itemset

        public Itemset()
        Standard Itemset constructor
    • Method Detail

      • addItem

        public void addItem(Item value)
        It adds an item to the itemset. The item is inserted in the last position.
        Parameters:
        value - The item to add
      • addItem

        public void addItem(int i,
                            Item value)
        It adds an item to the itemset. The item is inserted in the specified position.
        Parameters:
        i - index where we want to add the item
        value - The item to add
      • removeItem

        public void removeItem(Item value)
        It removes the specified item.
        Parameters:
        value - The item to remove
      • removeItem

        public Item removeItem(int i)
        It removes the item which appears in the specified index.
        Parameters:
        i - the intex
        Returns:
        the item that has been removed.
      • getItems

        public java.util.List<Item> getItems()
        It returns the items that compose the itemset.
        Returns:
        a list of items
      • get

        public Item get(int index)
        Get the item from the specified position.
        Parameters:
        index - The index where is the item in which we are interested.
        Returns:
        the item
      • toString

        public java.lang.String toString()
        Get a string representation of the itemset.
        Overrides:
        toString in class java.lang.Object
        Returns:
        the string representation
      • cloneItemSet

        public Itemset cloneItemSet()
        It clones the itemset.
        Returns:
        The clone itemset.
      • getTimestamp

        public long getTimestamp()
      • setTimestamp

        public void setTimestamp(long timestamp)
      • size

        public int size()
        It returns the number of items that compose the itemset.
        Returns:
        the number of items (int)
      • equals

        public boolean equals(java.lang.Object o)
        Check if this itemset is equal to another. Two itemsets are equals if in each position they have the same item.
        Overrides:
        equals in class java.lang.Object
        Parameters:
        o - the other itemset
        Returns:
        true if equal
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • getBeginning

        public int getBeginning()
      • setBeginning

        public void setBeginning(int inicio)

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.