• Home
  • History
  • Annotate
  • Line#
  • Navigate
  • Raw
  • Download
  • only in /netgear-WNDR4500v2-V1.0.0.60_1.0.38/ap/gpl/timemachine/db-4.7.25.NC/examples_java/src/collections/ship/index/
1/*-
2 * See the file LICENSE for redistribution information.
3 *
4 * Copyright (c) 2002,2008 Oracle.  All rights reserved.
5 *
6 * $Id: PartKey.java,v 12.7 2008/01/08 20:58:30 bostic Exp $
7 */
8
9package collections.ship.index;
10
11import java.io.Serializable;
12
13/**
14 * A PartKey serves as the key in the key/data pair for a part entity.
15 *
16 * <p> In this sample, PartKey is used both as the storage data for the key as
17 * well as the object binding to the key.  Because it is used directly as
18 * storage data using serial format, it must be Serializable. </p>
19 *
20 * @author Mark Hayes
21 */
22public class PartKey implements Serializable {
23
24    private String number;
25
26    public PartKey(String number) {
27
28        this.number = number;
29    }
30
31    public final String getNumber() {
32
33        return number;
34    }
35
36    public String toString() {
37
38        return "[PartKey: number=" + number + ']';
39    }
40}
41