Home > Articles > Programming > Java

Like this article? We recommend

Like this article? We recommend

Bean Components

An entity bean is composed of the following components:

  • Remote interface. The remote interface defines all the business methods for the bean; for an entity bean, these are usually composed of a set of get/set methods for the bean's attributes.

  • Home interface. The home interface defines the methods used to create entity beans and to locate specific beans; beans can be located (using a finder method) by a specific bean attribute or by a set of methods (custom finders), or all beans can be retrieved (find all).

  • Primary key class. The primary key class contains all fields that comprise the primary key for an entity bean and provides two methods: hash() and equals().

  • Bean class. The bean class provides the implementation for all the entity bean's business methods and some overhead lifetime methods.

In this example, I want to model a stock portfolio for a particular user. A portfolio contains the information shown in Table 1.

Table 1 Portfolio Table

Field

Description

Data Type

pk

Primary key

NUMBER

owner

Owner of the portfolio

VARCHAR

symbol

Stock symbol

VARCHAR

name

Company name

VARCHAR

purchasePrice

Purchase price per share

NUMBER

numberShares

Number of shares owned

NUMBER

recentPrice

Most recent price

NUMBER

Remote Interface

The remote interface defines the business methods for the EJB. Listing 1 shows the remote interface for the portfolio. Note that all the methods are declared as being abstract; this is a requirement defined in the JBoss documentation.

Listing 1 Portfolio Remote Interface (Portfolio.java)

package com.informit.javasolutions.portfolio;

// Import the EJB classes
import java.rmi.RemoteException;
import javax.ejb.*;

/**
 * Entity Bean Remote Interface for the Certificate Object
 */
public interface Portfolio extends EJBObject
{
    public abstract int getPk() throws RemoteException;

    public abstract String getOwner() throws RemoteException;
    public abstract void setOwner( String owner )
           throws RemoteException;

    public abstract String getSymbol() throws RemoteException;
    public abstract void setSymbol( String symbol )
           throws RemoteException;

    public abstract String getName() throws RemoteException;
    public abstract void setName( String name )
           throws RemoteException;

    public abstract float getPurchasePrice() throws RemoteException;
    public abstract void setPurchasePrice( float purchasePrice )
           throws RemoteException;

    public abstract int getNumberShares() throws RemoteException;
    public abstract void setNumberShares( int numberShares )
           throws RemoteException;

    public abstract float getRecentPrice() throws RemoteException;
    public abstract void setRecentPrice( float recentPrice )
           throws RemoteException;

}

The portfolio interface is nothing more than a set of get/set methods for the entity bean's fields. All remote interfaces must extend the javax.ejb.EJBObject interface and declare that all methods can throw java.rmi.RemoteException. Table 2 lists the methods that are inherited by the EJBObject interface.

Table 2 EJBObject Interface

Method

Description

EJBHome getEJBHome()

Obtains the enterprise bean's home interface.

Handle getHandle()

Obtains a handle for the EJB object.

java.lang.Object getPrimaryKey()

Obtains the primary key of the EJB object.

boolean isIdentical(EJBObject obj)

Tests whether a given EJB object is identical to the invoked EJB object.

void remove()

Removes the EJB object.

Home Interface

The home interface defines two categories of methods: create methods and finder methods. Listing 2 shows the PortfolioHome interface.

Listing 2 Portfolio Home Interface (PortfolioHome.java)

package com.informit.javasolutions.portfolio;

// Import the EJB classes
import java.rmi.RemoteException;
import javax.ejb.*;

// Import the Collection classes
import java.util.Collection;

/**
 * Defines the Home interface for the Portfolio EntityBean
 */
public interface PortfolioHome extends EJBHome
{
    /**
     * Create method with all non-nullable fields
     */
    public Portfolio create( int pk,
                             String owner,
                             String symbol )
           throws RemoteException, CreateException;

    /**
     * Create method with all fields
     */
    public Portfolio create( int pk,
                             String owner,
                             String symbol,
                             String name,
                             float purchasePrice,
                             int numberShares,
                             float recentPrice ) 
           throws RemoteException, CreateException;

    /**
     * Find a portfolio by its primary key
     */
    public Portfolio findByPrimaryKey( PortfolioPk pk ) 
           throws RemoteException, FinderException;

    /**
     * Find all portfolios owned by a specified owner
     */
    public Collection findByOwner( String owner ) 
           throws RemoteException, FinderException;

    /**
     * Find all portfolios
     */
    public Collection findAll() throws
           RemoteException, FinderException;

}

All home interfaces must extend the javax.ejb.EJBHome interface (shown in Table 3) and must declare that all methods can throw java.rmi.RemoteException. Furthermore, all create methods must declare that they can throw javax.ejb.CreateException, and all finder methods must declare that they can throw javax.ejb.FinderException.

The only required finder method is findByPrimaryKey(), which returns an instance of the remote interface. Other finder methods are optional and return a collection of remote interface instances; findAll() returns all records in the database and the findByXXX() methods return all records that match a specific field. When using JBoss, you can specify findByXXX(), where XXX is one of the bean's CMP managed fields, and it will generate the code to load those records for you!

Table 3 EJBHome Interface

Method

Description

EJBMetaData getEJBMetaData()

Obtains the EJBMetaData interface for the enterprise bean.

HomeHandle getHomeHandle()

Obtains a handle for the home object.

void remove(Handle handle)

Removes an EJB object identified by its handle.

void remove(java.lang.Object primaryKey)

Removes an EJB object identified by its primary key.

Primary Key Class

The primary key class holds all the fields that comprise the primary key for the bean. In JBoss, this class is not necessary for beans with a single primary key value, and can be specified in the bean's deployment descriptor. It's good practice to develop this class and essential for tables with a primary key that spans multiple columns. Listing 3 shows the portfolio's primary key class.

Listing 3 Portfolio's Primary Key Class (PortfolioPk.java)

package com.informit.javasolutions.portfolio;

/**
 * Primary Key class for the Portfolio Entity Bean
 */
public class PortfolioPk implements java.io.Serializable
{
    /**
     * Holds the primary key
     */
    public int pk;

    /**
     * Creates a new Portfolio Primary Key Object
     */
    public PortfolioPk()
    {
    }

    /**
     * Creates and initializes a new Portfolio Primary Key Object
     */
    public PortfolioPk( int pk )
    {
        this.pk = pk;
    }

    /**
     * From Serializable we must implement the hashCode method
     * and provide a unique id for this class - let's use the
     * primary key, it has to be unique!
     */
    public int hashCode()
    {
        return pk;
    }

    /**
     * See if these objects are the same
     */
    public boolean equals( Object obj )
    {
        if( obj instanceof PortfolioPk )
        {
            return( pk == ( ( PortfolioPk )obj ).pk );
        }

        return false;
    }

}

The primary key class must be serializable (implement java.io.Serializable) and must define two methods: hashCode() and equals() (see Table 4). Furthermore, it must have public attributes for all columns that comprise the bean's primary key; EJB uses introspection and reflection to find a bean's attributes and methods, and imposes the restriction that all CMP attributes must be public.

Table 4 Primary Key Required Methods

Method

Description

boolean equals(Object obj)

Indicates whether some other object obj is "equal to" this one.

int hashCode()

Returns a hash code value for the object.

Bean Class

The bean class is the meat of the EJB; it implements the business methods defined in the remote interface. Listing 4 shows the source code for the Portfolio Bean class.

Listing 4 Portfolio's Bean Class (PortfolioBean.java)

package com.informit.javasolutions.portfolio;

// Import the EJB classes
import java.rmi.RemoteException;
import javax.ejb.*;

// Import the JNDI classes
import javax.naming.*;
import javax.rmi.PortableRemoteObject;

// Import the IO classes
import java.io.*;

// Import the Collection classes
import java.util.*;

public class PortfolioBean implements EntityBean
{
    /**
     * Entity context
     */
    transient private EntityContext ctx;

    /**
     * CMP Managed fields
     */
    public int pk;
    public String owner;
    public String symbol;
    public String name;
    public float purchasePrice;
    public int numberShares;
    public float recentPrice;

    /**
     * Create method - must implement because PortfolioHome defined
     * a create method with this signature returns a PortfolioPk
     * object (as null because we are using container managed
     * persistence - container creates the primary key)
     */
    public PortfolioPk ejbCreate( int pk,
                                  String owner,
                                  String symbol ) {
        this.pk = pk;
        this.owner = owner;
        this.symbol = symbol;

        return null;
    }

    /**
     * Create method with all fields
     */
    public PortfolioPk ejbCreate( int pk,
                                  String owner,
                                  String symbol,
                                  String name,
                                  float purchasePrice,
                                  int numberShares,
                                  float recentPrice ) {
        this.pk = pk;
        this.owner = owner;
        this.symbol = symbol;
        this.name = name;
        this.purchasePrice = purchasePrice;
        this.numberShares = numberShares;
        this.recentPrice = recentPrice;

        return null;
    }


    /**
     * Must have an ejbPostCreate() method matching the signature of
     * each ejbCreate() method - performs any follow-up operations
     */
    public void ejbPostCreate( int pk,
                               String owner,
                               String symbol ) {
    }

    /**
     * Create method with all fields
     */
    public void ejbPostCreate( int pk,
                               String owner,
                               String symbol,
                               String name,
                               float purchasePrice,
                               int numberShares,
                               float recentPrice ) {
    }

    /**
     * Implement the business methods in the Portfolio Remote
     * Interface
     */
    public int getPk() {
        return this.pk;
    }

    public String getOwner() {
        return this.owner;
    }

    public void setOwner( String owner ) {
        this.owner = owner;
    }

    public String getSymbol() {
        return this.symbol;
    }

    public void setSymbol( String symbol ) {
        this.symbol = symbol;
    }

    public String getName() {
        return this.name;
    }

    public void setName( String name ) {
        this.name = name;
    }

    public float getPurchasePrice() {
        return this.purchasePrice;
    }

    public void setPurchasePrice( float purchasePrice ) {
        this.purchasePrice = purchasePrice;
    }

    public int getNumberShares() {
        return this.numberShares;
    }

    public void setNumberShares( int numberShares ) {
        this.numberShares = numberShares;
    }

    public float getRecentPrice() {
        return this.recentPrice;
    }

    public void setRecentPrice( float recentPrice ) {
        this.recentPrice = recentPrice;
    }

    /**
     * Saves the Bean's entity context
     */
    public void setEntityContext( EntityContext ctx ) {
        this.ctx = ctx;
    }

    /**
     * Destroys the Bean's entity context
     */
    public void unsetEntityContext() {
        ctx = null;
    }

    /**
     * Unused EntityBean interface methods
     */
    public void ejbActivate() {}
    public void ejbPassivate() {}
    public void ejbRemove() {}
    public void ejbLoad() {}
    public void ejbStore() {}
}

All EJBs must implement the javax.ejb.EnterpriseBean interface (a marker interface); entity beans implement javax.ejb.EntityBean, which extends javax.ejb.EnterpriseBean, and session beans implement javax.ejb.SessionBean, which also extends javax.ejb.EnterpriseBean. Table 5 shows the methods defined in the javax.ejb.EntityBean interface.

Table 5 javax.ejb.EntityBean Interface Methods

Method

Description

void ejbActivate()

A container invokes this method when the instance is taken out of the pool of available instances to become associated with a specific EJB object.

void ejbLoad()

A container invokes this method to instruct the instance to synchronize its state by loading its state from the underlying database.

void ejbPassivate()

A container invokes this method on an instance before the instance becomes disassociated from a specific EJB object.

void ejbRemove()

A container invokes this method before it removes the EJB object that's currently associated with the instance.

void ejbStore()

A container invokes this method to instruct the instance to synchronize its state by storing it to the underlying database.

void setEntityContext(EntityContext ctx)

Sets the associated entity context ctx.

void unsetEntityContext()

Unsets the associated entity context.

All CMP entity beans must provide publicly accessible attributes for all fields that will be persisted to the database (again this is because of EJB constraints imposed by its use of introspection and reflection). The names of these fields must match the corresponding business methods in the remote interface; for example, if there is a method getOwner() that returns a java.lang.String, there must be a corresponding field owner of type java.lang.String. (Note that this is only required for CMP managed fields—more on that in future articles.)

EJBs implement all the methods defined in the remote interface, but notice that the bean doesn't implement the remote interface directly. The method names will be resolved at deployment time, but because the EJB doesn't implement its remote interface directly it's confusing at first.

EJBs are required to provide an ejbCreate() method with a matching signature to each of the create() methods defined in the bean's home interface, with the exception that instead of returning an instance of the remote interface, it returns an instance of the primary key class. CMP beans are required to return null. Furthermore, each ejbCreate() method must be accompanied by an ejbPostCreate() method.

Finally, notice that the bean is required to provide implementations of all the methods defined in the javax.ejb.EntityBean interface. Most of these methods will be useful when using BMP, so we'll just provide placeholders for now.

Compilation

Place all four of the files from Listings 1[nd]4 in the following package:

com.infomit.javasolutions.portfolio

Recall that the directory structure mimics the package:

com/infomit/javasolutions/portfolio

Using the JDK 1.3, compile these four files with the following files added to your CLASSPATH:

YOUR_JBOSS_HOME/lib/ext/ejb.jar

If you're not using the JDK 1.3, you need to include JBoss's jndi.jar file as well as the Java 2, Enterprise Edition's j2ee.jar.

Deployment

Unlike standard Java applications or applets, EJBs must be deployed to an EJB container. For the EJB container to know the location of the files that comprise the bean and their respective roles, we must develop a deployment descriptor. Listing 5 shows the contents of our deployment descriptor.

Listing 5 Portfolio Deployment Descriptor (ejb-jar.xml)

<?xml version="1.0"?>

<!DOCTYPE ejb-jar PUBLIC
   "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 1.1//EN"
   "http://java.sun.com/j2ee/dtds/ejb-jar_1_1.dtd">

<ejb-jar>
  <display-name>StockBeans</display-name>
  <enterprise-beans>

    <entity>
      <description>Represents a Portfolio record in the database
      </description>
      <ejb-name>PortfolioBean</ejb-name>
      <home>com.informit.javasolutions.portfolio.PortfolioHome</home>
      <remote>com.informit.javasolutions.portfolio.Portfolio</remote>
      <ejb-class>com.informit.javasolutions.portfolio.PortfolioBean
      </ejb-class>
      <persistence-type>Container</persistence-type>
      <prim-key-class>com.informit.javasolutions.portfolio.PortfolioPk
      </prim-key-class>
      <reentrant>False</reentrant>

      <cmp-field><field-name>pk</field-name></cmp-field>
    </entity>

  </enterprise-beans>

  <assembly-descriptor>
    <container-transaction>
      <method>
        <ejb-name>PortfolioBean</ejb-name>
        <method-name>*</method-name>
      </method>
      <trans-attribute>Required</trans-attribute>
    </container-transaction>
  </assembly-descriptor>
</ejb-jar>

All deployment descriptors are named ejb-jar.xml and have an <enterprise-beans> tag that defines all entity beans and session beans. Entity beans are defined by an <entity> tag and session beans are defined by a <session> tag. In the portfolio deployment descriptor we have one entity bean, and hence one <entity> tag.

Table 6 describes the deployment descriptor tags used in Listing 5.

Table 6 Deployment Descriptor Tags

Tag

Description

<description>

Describes this entity bean, for use with some GUI deployment applications.

<ejb-name>

Names the bean; this name references this bean elsewhere in the ejb-jar.xml file as well as in custom deployment files.

<home>

Defines the fully qualified name of the entity bean's home interface.

<remote>

Defines the fully qualified name of the entity bean's remote interface.

<prim-key-class>

Defines the fully qualified name of the primary key class.

<ejb-class>

Defines the fully qualified name of the entity bean's bean class.

<persistence-type>

Defines who manages the persistence for this bean; it can be either "Container" or "Bean".

<cmp-field>

Notes all fields that are container managed—if the name of the field directly matches the table column names, you can omit these entries.

<assembly-descriptor>

Defines transactional information that I'll use in later articles when I start talking about JTA, so for now just leave that alone.

Once you have this deployment descriptor and your classes in place, you must package your EJB into a JAR file with the following directory structure:

com/informit/javasolutions/portfolio/Portfolio.class
com/informit/javasolutions/portfolio/PortfolioHome.class
com/informit/javasolutions/portfolio/PortfolioPk.class
com/informit/javasolutions/portfolio/PortfolioBean.class

META-INF/ejb-jar.xml

From the folder that contains your com folder, you can build this JAR file with the following command:

jar cf stock.jar com/informit/javasolutions/portfolio/*.class

                 META-INF/*.xml

This will build a file called stock.jar that contains your entity bean. The last step is to copy this file to JBoss's deploy directory. If you have JBoss running, you can watch its text display show you the deployment; if not, start JBoss by executing its run.bat file from its bin directory and look for your bean! You should see something similar to the following:

...
[J2EE Deployer] Create application stock.jar
[J2EE Deployer] Installing EJB package: stock.jar
[J2EE Deployer] Starting module stock.jar
[Container factory] Deploying:file:/
        D:/jBoss-2.0_FINAL/bin/../tmp/deploy/stock.jar/ejb1006.jar
[Verifier] Verifying file:/
        D:/jBoss-2.0_FINAL/bin/../tmp/deploy/stock.jar/ejb1006.jar

[Container factory] Deploying PortfolioBean

If you see any exceptions, read through them and try to troubleshoot the problem; most errors are fairly easy to interpret and involve a missing file from the JAR file, a misspelling, or a case-sensitivity issue (uppercase versus lowercase).

Test Client

Developing an entity bean isn't going to do you much good unless you have a test client with which to look at the bean. Listing 6 shows a test client for the portfolio bean.

Listing 6 Porfolio Test Client (PortfolioTest.java)

import com.informit.javasolutions.portfolio.Portfolio;
import com.informit.javasolutions.portfolio.PortfolioHome;
import com.informit.javasolutions.portfolio.PortfolioPk;

// Import the EJB classes
import java.rmi.RemoteException;
import javax.ejb.*;

// Import the JNDI classes
import javax.naming.*;
import javax.rmi.PortableRemoteObject;

// Import the Java Collection classes
import java.util.*;

public class PortfolioTest
{
    public static void main( String[] args ) {
        System.setProperty( "java.naming.factory.initial",
                           "org.jnp.interfaces.NamingContextFactory");
        System.setProperty( "java.naming.provider.url",
                            "localhost:1099");

        try {
            // Get a naming context
            InitialContext jndiContext = new InitialContext();
            System.out.println("Got context");

            // Get a reference to the Interest Bean
            Object ref  = jndiContext.lookup( "PortfolioBean" );
            System.out.println("Got reference");

            // Get a reference from this to the Bean's Home interface
            PortfolioHome home = ( PortfolioHome )
              PortableRemoteObject.narrow( ref, PortfolioHome.class );

            // Create an Interest object from the Home interface
            for( int i=1; i<=20; i++ ) {
                Portfolio portfolio = home.create( i,
                                                   "Steve",
                                                   "Symbol " + i );
            }

            // Find our portfolio
            Collection portfolios = home.findAll();
            Iterator i = portfolios.iterator();
            while( i.hasNext() ) {
                Portfolio thisPortfolio = ( Portfolio )i.next();
                System.out.println( "Portfolio " +
                                    thisPortfolio.getPk() +
                                    ": " + 
                                    thisPortfolio.getOwner() +
                                    " = " + 
                                    thisPortfolio.getSymbol() );
            }
        }
        catch( Exception e ) {
            e.printStackTrace();
        }
    }
}

To connect to JBoss's JNDI server, we must set a couple of system properties:

System.setProperty( "java.naming.factory.initial",
                    "org.jnp.interfaces.NamingContextFactory");
System.setProperty( "java.naming.provider.url",
                    "localhost:1099");

The naming factory is the class that JNDI will use to locate JBoss's JNDI server, and the provider URL is the network location of the machine that JBoss is running on. In this example, we're running on the same machine and hence we'll use localhost on the standard RMI port 1099.

Next, we create an instance of the javax.naming.InitialContext class; this uses the system properties we specified to connect to JBoss. To find the bean we're looking for (PortfolioBean), we use the InitialContext's lookup() method; this returns an object reference that we need to resolve to the entity bean's home interface.

NOTE

You may read in many books that you can cast this object directly to the home interface—and this will work in almost all cases—but because EJB can be used with CORBA objects through RMI/IIOP, the object is not necessarily a Java object, and must be "narrowed." The javax.rmi.PortableRemoteObject class provides a static method narrow() that tests to make sure that the conversion is permissible and returns the correct object.

Once we have a reference to the home interface, we can start calling its create and finder methods. This example creates 20 portfolio records and then calls findAll() to look them up and display them. Try playing around with the findByOwner() method and adding some records of your own.

CAUTION

Note that if you run this twice in a row you'll run into problems because we're hard-coding the primary keys—and primary keys must be unique! During subsequent tests, comment out the create calls or dynamically generate your primary keys (more to come in future articles on primary key generation).

When you're tired of using some of the records, you can remove them through the Home interface's remove() method—pass it an instance of the entity bean's primary key class:

home.remove( new PortfolioPk( 1 ) );

InformIT Promotional Mailings & Special Offers

I would like to receive exclusive offers and hear about products from InformIT and its family of brands. I can unsubscribe at any time.

Overview


Pearson Education, Inc., 221 River Street, Hoboken, New Jersey 07030, (Pearson) presents this site to provide information about products and services that can be purchased through this site.

This privacy notice provides an overview of our commitment to privacy and describes how we collect, protect, use and share personal information collected through this site. Please note that other Pearson websites and online products and services have their own separate privacy policies.

Collection and Use of Information


To conduct business and deliver products and services, Pearson collects and uses personal information in several ways in connection with this site, including:

Questions and Inquiries

For inquiries and questions, we collect the inquiry or question, together with name, contact details (email address, phone number and mailing address) and any other additional information voluntarily submitted to us through a Contact Us form or an email. We use this information to address the inquiry and respond to the question.

Online Store

For orders and purchases placed through our online store on this site, we collect order details, name, institution name and address (if applicable), email address, phone number, shipping and billing addresses, credit/debit card information, shipping options and any instructions. We use this information to complete transactions, fulfill orders, communicate with individuals placing orders or visiting the online store, and for related purposes.

Surveys

Pearson may offer opportunities to provide feedback or participate in surveys, including surveys evaluating Pearson products, services or sites. Participation is voluntary. Pearson collects information requested in the survey questions and uses the information to evaluate, support, maintain and improve products, services or sites, develop new products and services, conduct educational research and for other purposes specified in the survey.

Contests and Drawings

Occasionally, we may sponsor a contest or drawing. Participation is optional. Pearson collects name, contact information and other information specified on the entry form for the contest or drawing to conduct the contest or drawing. Pearson may collect additional personal information from the winners of a contest or drawing in order to award the prize and for tax reporting purposes, as required by law.

Newsletters

If you have elected to receive email newsletters or promotional mailings and special offers but want to unsubscribe, simply email information@informit.com.

Service Announcements

On rare occasions it is necessary to send out a strictly service related announcement. For instance, if our service is temporarily suspended for maintenance we might send users an email. Generally, users may not opt-out of these communications, though they can deactivate their account information. However, these communications are not promotional in nature.

Customer Service

We communicate with users on a regular basis to provide requested services and in regard to issues relating to their account we reply via email or phone in accordance with the users' wishes when a user submits their information through our Contact Us form.

Other Collection and Use of Information


Application and System Logs

Pearson automatically collects log data to help ensure the delivery, availability and security of this site. Log data may include technical information about how a user or visitor connected to this site, such as browser type, type of computer/device, operating system, internet service provider and IP address. We use this information for support purposes and to monitor the health of the site, identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents and appropriately scale computing resources.

Web Analytics

Pearson may use third party web trend analytical services, including Google Analytics, to collect visitor information, such as IP addresses, browser types, referring pages, pages visited and time spent on a particular site. While these analytical services collect and report information on an anonymous basis, they may use cookies to gather web trend information. The information gathered may enable Pearson (but not the third party web trend services) to link information with application and system log data. Pearson uses this information for system administration and to identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents, appropriately scale computing resources and otherwise support and deliver this site and its services.

Cookies and Related Technologies

This site uses cookies and similar technologies to personalize content, measure traffic patterns, control security, track use and access of information on this site, and provide interest-based messages and advertising. Users can manage and block the use of cookies through their browser. Disabling or blocking certain cookies may limit the functionality of this site.

Do Not Track

This site currently does not respond to Do Not Track signals.

Security


Pearson uses appropriate physical, administrative and technical security measures to protect personal information from unauthorized access, use and disclosure.

Children


This site is not directed to children under the age of 13.

Marketing


Pearson may send or direct marketing communications to users, provided that

  • Pearson will not use personal information collected or processed as a K-12 school service provider for the purpose of directed or targeted advertising.
  • Such marketing is consistent with applicable law and Pearson's legal obligations.
  • Pearson will not knowingly direct or send marketing communications to an individual who has expressed a preference not to receive marketing.
  • Where required by applicable law, express or implied consent to marketing exists and has not been withdrawn.

Pearson may provide personal information to a third party service provider on a restricted basis to provide marketing solely on behalf of Pearson or an affiliate or customer for whom Pearson is a service provider. Marketing preferences may be changed at any time.

Correcting/Updating Personal Information


If a user's personally identifiable information changes (such as your postal address or email address), we provide a way to correct or update that user's personal data provided to us. This can be done on the Account page. If a user no longer desires our service and desires to delete his or her account, please contact us at customer-service@informit.com and we will process the deletion of a user's account.

Choice/Opt-out


Users can always make an informed choice as to whether they should proceed with certain services offered by InformIT. If you choose to remove yourself from our mailing list(s) simply visit the following page and uncheck any communication you no longer want to receive: www.informit.com/u.aspx.

Sale of Personal Information


Pearson does not rent or sell personal information in exchange for any payment of money.

While Pearson does not sell personal information, as defined in Nevada law, Nevada residents may email a request for no sale of their personal information to NevadaDesignatedRequest@pearson.com.

Supplemental Privacy Statement for California Residents


California residents should read our Supplemental privacy statement for California residents in conjunction with this Privacy Notice. The Supplemental privacy statement for California residents explains Pearson's commitment to comply with California law and applies to personal information of California residents collected in connection with this site and the Services.

Sharing and Disclosure


Pearson may disclose personal information, as follows:

  • As required by law.
  • With the consent of the individual (or their parent, if the individual is a minor)
  • In response to a subpoena, court order or legal process, to the extent permitted or required by law
  • To protect the security and safety of individuals, data, assets and systems, consistent with applicable law
  • In connection the sale, joint venture or other transfer of some or all of its company or assets, subject to the provisions of this Privacy Notice
  • To investigate or address actual or suspected fraud or other illegal activities
  • To exercise its legal rights, including enforcement of the Terms of Use for this site or another contract
  • To affiliated Pearson companies and other companies and organizations who perform work for Pearson and are obligated to protect the privacy of personal information consistent with this Privacy Notice
  • To a school, organization, company or government agency, where Pearson collects or processes the personal information in a school setting or on behalf of such organization, company or government agency.

Links


This web site contains links to other sites. Please be aware that we are not responsible for the privacy practices of such other sites. We encourage our users to be aware when they leave our site and to read the privacy statements of each and every web site that collects Personal Information. This privacy statement applies solely to information collected by this web site.

Requests and Contact


Please contact us about this Privacy Notice or if you have any requests or questions relating to the privacy of your personal information.

Changes to this Privacy Notice


We may revise this Privacy Notice through an updated posting. We will identify the effective date of the revision in the posting. Often, updates are made to provide greater clarity or to comply with changes in regulatory requirements. If the updates involve material changes to the collection, protection, use or disclosure of Personal Information, Pearson will provide notice of the change through a conspicuous notice on this site or other appropriate way. Continued use of the site after the effective date of a posted revision evidences acceptance. Please contact us if you have questions or concerns about the Privacy Notice or any objection to any revisions.

Last Update: November 17, 2020