BEA Logo BEA WLCS Release 3.5

  BEA Home  |  Events  |  Solutions  |  Partners  |  Products  |  Services  |  Download  |  Developer Center  |  WebSUPPORT

 

   WLCS Documentation   |   Building Personalized Applications   |   Previous Topic   |   Next Topic   |   Contents   |   Index

Creating and Managing Property Sets

 

Property sets are the schemas for personalization attributes. Using the Property Set Management tool, you can create property sets and define the properties that make up these property sets.

This chapter includes the following topics:

 


Overview of Property Sets

In the most general sense, a property can be considered a name/value pair. Property sets serve as namespaces for properties so that properties can be conveniently grouped and so that multiple properties with the same name can be defined.

For instance, Web site developers might want users to be able to specify different background colors for each of their portals by requiring the property "backgroundColor" for a user. By creating "portalA" and "portalB" property sets, the property "backgroundColor" can exist for both portalA and portalB. While the two "backgroundColor" properties have the same name, they could have the same or different definitions. Figure 1-5 shows two property sets with redundant property names, corresponding to unique definitions.

Figure 1-5 Property Sets Serving as Namespaces


 
 
 
 

A property definition includes the following information:

For Personalization Server purposes, property sets are applied to six major areas.

  1. User and Group Profiles

    The User/Group property set type is used for defining the property sets and properties that apply to user and group profiles. For example, a property set of this type might be created called portalA. Subsequent property retrieval for a particular user or group can then be scoped with this property set name to retrieve the user's background color for the portal. See Creating and Managing Users, for an in-depth discussion of how property retrieval works for users and groups.

  2. HTTP Sessions

    The Session property set type is used for defining the property sets and properties that apply to HTTP sessions. Like the User/Group property set type, a "Session" property set type might be called "portalA." Properties available through this property set can then be accessed via the Advisor.

  3. HTTP Requests

    The Request property set type is used for defining the property sets and properties that apply to HTTP requests. Again, like the "User/Group" property set type, a "Request" property set type might be called "portalA." Properties available through this property set can then be accessed via the Advisor.

  4. Content Management

    The Content Management property set type is used for defining the configuration and run-time use of the content management system. Content Management property sets cannot be created or manipulated with the Personalization Server Administration Tools. For more complete information on this subject, see Creating and Managing Content, in this guide.

  5. Application Initialization

    The Application Init property set type uses default values to define application initialization parameters. These are the property sets used by the Flow Manager in support of portal (DEFAULT_PORTAL_INIT) and non-portal (DEFAULT_APP_INIT) based personalized applications. For more information about the Flow Manager, see Foundation Classes and Utilities, in this guide.

  6. Catalog Custom Attributes

    You can define a property set that establishes custom attributes for a product item in the WebLogic Commerce Server catalog. For a given product item, a custom attribute that you define can be used in addition to the default attributes provided by WebLogic Commerce Server in the catalog database tables. For more information, see "Catalog Administration Tasks" in the Guide to Building a Product Catalog.

Creating a property set is a simple task via the Property Set Management tools. A name for the set must be provided as well as description. Properties can be copied from an existing property set if a pre-existing property set defines similar properties. Expanding the previous example, if portalA's properties have been defined and portalB is going to have the same (or similar) properties, then you can copy the properties from portalA's property set when creating portalB's property set. Finally, the type of property set ("User/Group", "Session", or "Request") must be chosen.

When defining a property, specify the following:

The following table lists the property definition attribute and value.

Property Definition Attribute

Attribute Value

Name

Text (100 character length maximum)

Description

Text (255 character length maximum)

Type

Text, Integer (equivalent to Long in Java), Floating-Point Number (equivalent to Double in Java), Boolean, or Date/Time

Selection Option

Single-valued or multi-valued

Creation Category

Restricted or unrestricted

Default Value

Up to the user-can be null


 

Once created, User/Group property values can be edited for a particular user or group via the User Management user and group tools. For "Session" and "Request" properties, the only editable values are the default values set in the property definitions -run-time values are determined by values in the HTTP session or HTTP request, respectively.

 


Property Value Retrieval via ConfigurableEntity

Property Sets created with the administration tools are stored as com.beasys.commerce.foundation.property.Schema components. The component that acts as an "owner" of properties associated with Property Sets is the com.beasys.commerce.foundation.ConfigurableEntity. During inspection of the Javadoc for Schema and ConfigurableEntity, the reader may see the words "schema" and "scope" used interchangeably with "Property Set." Figure 1-6 shows a simplified representation of property value retrieval through a ConfigurableEntity. For the ConfigurableEntity, the value of backgroundColor for portalB has been overridden. The value of backgroundColor for portalA has not. Therefore, when backgroundColor is requested for the portalB property set, the overridden value, red, will be returned. When backgroundColor is requested for the portalA property set, the property set default value, white, will be returned.

Figure 1-6 backgroundColor Property Retrieval


 

Figure 1-7 shows another simple example of backgroundColor property retrieval to demonstrate the notion of an explicit successor. A second ConfigurableEntity can be specified in the ConfigurableEntity getProperty() API that acts as a "backup" place to look for a particular property value. This second ConfigurableEntity is considered an explicit property successor. In this example, a particular group is used as an explicit successor, and the value for portalA's background color, green, is "inherited" from this successor.

Figure 1-7 Explicit Successor backgroundColor Property Retrieval


 

Figure 1-8 provides an example of an implicit successor. An implicit successor is a successor tied to a particular Property Set. In this case, the user does not have a value for portalA.backgroundColor, and no explicit successor is provided in the getProperty() call. However, the group has already been associated with the user as its successor for the portalA Property Set. Again, the user "inherits" the property value, green, from the group.

Figure 1-8 Property Inheritance Through Property Set-related Successor


 

There also exists the notion of a default successor, which can be searched after an explicit successor and a Property Set-related successor have failed to return a value for the property. Figure 1-9 shows such a case. In this example, the Property Set-related successor cannot produce the necessary property value for backgroundColor in portalA, so the value must be retrieved from the default successor.

Figure 1-9 Property Inheritance Through a Default Successor


 

Keep in mind that these examples have been considerably simplified for brevity and to easily explain relevant concepts. More details of ConfigurableEntity property inheritance are available in the topic Users and Groups in the chapter Creating and Managing Users.

 


Using the Property Set Management Tool


 

The Property Set Management tools allow you to create and manage sets of typed properties. Property Sets may be defined to describe user and group, session, request, and content properties.

Creating Property Sets

To create a property set:

  1. On the Administration Tools Home page, click the Property Set Management icon. The Property Set Management Home page appears.

  2. Click Create in the Property Sets banner. The Create Property Set page appears.

    To enter a new property set:

    1. Enter the name of the new property set in the Name field.

    2. Enter a description of the new property set in the Description field.

    3. Leave the Copy Properties From default as Don't copy properties.

    4. From the Property Set Type drop-down list, select a property set type.

      To copy properties from an existing property set into the new one:

    5. Enter the name of the new property set in the Name field.

    6. Enter a description of the new property set in the Description field.

    7. From the Copy Properties From drop-down list, select the property set containing the properties you want copied.

  3. Click Create to create the property set.

  4. Click Back to return to the Property Set Management Home page.

Note: At any time, you can click Back to return to the Property Set Management Home page without saving the property set.

Creating Properties Within a Property Set

To create properties within a property set:

  1. On the Administration Tools Home page, click the Property Set Management icon. The Property Set Management Home page appears.

  2. From the Property Set list, click the title link for the property set to which you will add a property. The Property Set view page appears.

  3. Click Create on the Properties bar. The Create Properties page appears.
     

    1. Enter the property name in the Property Name field.

    2. Enter a description of the new property in the Description field.

    3. Select the type from the Type drop-down list box.

    4. Select option (single, multiple) from the Selection Option drop-down list box.

      Note: The single option refers to those properties having only one option (for example, Property: Color, Attribute: red). The multiple option refers to those properties having multiple options (for example, Property: Colors, Attributes: red, green, blue, and so on).

    5. Select the creation of category (Restricted, Unrestricted) from the Creation Category drop-down box.

      Note: Restricted categories refer to values that are selected via a list, radio buttons, check boxes, and so on. Unrestricted categories refer to instances in which users populate a form field.

  4. Click Create.

  5. Click Back to return to the Property Set view.

Setting Up the Property Default Value

Notes: Different steps are required for setting up default values, given your option/category selection.

To set up the property default value for single/restricted categories:

  1. From Property Set view, click Edit on the appropriate Property Description bar.

  2. Click Edit on the Properties Values bar.

  3. Enter a new value to the property in the New Value field.

  4. Click Create. The new value appears in the Values matrix at the bottom of the page.

  5. Indicate the default value(s) by selecting the appropriate radio button.

  6. Click Create.

To set up the property default value for single/unrestricted categories:

  1. From Property Set view, click Edit on the appropriate Property Set Description bar.

  2. Click Edit on the Properties Values bar.

  3. Enter a new value to the property in the New Value field.

  4. Click Create.

To set up the property default value for multiple/restricted categories:

  1. From Property Set view, click Edit on the appropriate Property Set Description bar.

  2. Click Edit on the Properties Values bar.

  3. Enter a new value to the property in the New Value field.

  4. Click Create. The new value appears in the Values matrix at the bottom of the page.

  5. Indicate the default value(s) by selecting the appropriate radio button(s).

  6. Click Create.

To set up the property default value for multiple/unrestricted categories:

  1. From Property Set view, click Edit on the appropriate Property Set Description bar.

  2. Click Edit on the Properties Values bar.

  3. Enter a new value to the property in the New Value field.

  4. Click Save.

Editing Property Sets

To edit a property set:

  1. On the Administration Tools Home page, click the Property Set Management icon. The Property Set Management Home page appears.

  2. Click the appropriate title link from the Property Sets list. The Property Set view page appears.

To edit the Property Set Description:

  1. Click Edit on the Property Set Description bar. The Edit Property Set page appears.
     

  2. Enter the new description in the Description field.

  3. Click Save to save changes. The general Property Set view appears with the new information. Alternately, click Back to return to Property Set view page without saving your changes.

Editing Properties Within a Property Set

To edit properties within a property set:

  1. On the Administration Tools Home page, click the Property Set Management icon. The Property Set Management Home page appears.

  2. Click the appropriate title link from the Property Sets list. The Property Set view page appears.

  3. Click Edit on the appropriate property bar. The specific Property view page appears, containing information specific to the property you wish to edit.

  4. Click Edit on the appropriate Description or Property Values bar. The Edit Property page appears.

  5. Enter changes in the field(s) provided.

  6. Click Save. The specific Property view returns. Alternatively, click Back. The specific Property view appears and your changes are not saved.

Deleting Property Sets

To delete a property set:

  1. On the Administration Tools Home page, click the Property Set Management icon. The Property Set Management Home page appears.

  2. Click the X to the right of the appropriate title link from the Property Sets list.

  3. Click OK to confirm the deletion.

Deleting Properties

To delete properties:

  1. On the Administration Tools Home page, click the Property Set Management icon. The Property Set Management Home page appears.

  2. Select the appropriate title link from the Property Sets list. The general Property Set view appears.

  3. Click Delete on the Properties bar. The Delete Properties page appears.
     

  4. Select a property from the Property Name list.

  5. Click Delete.

  6. Click OK to confirm the deletion. The specific Property view returns. Alternatively, click Back. The Property view appears and the property is not deleted.

 

back to top previous page next page