• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2 * Conditions Of Use
3 *
4 * This software was developed by employees of the National Institute of
5 * Standards and Technology (NIST), an agency of the Federal Government
6 * and others.
7 * Pursuant to title 15 Untied States Code Section 105, works of NIST
8 * employees are not subject to copyright protection in the United States
9 * and are considered to be in the public domain.  As a result, a formal
10 * license is not needed to use the software.
11 *
12 * This software is provided by NIST as a service and is expressly
13 * provided "AS IS."  NIST MAKES NO WARRANTY OF ANY KIND, EXPRESS, IMPLIED
14 * OR STATUTORY, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTY OF
15 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, NON-INFRINGEMENT
16 * AND DATA ACCURACY.  NIST does not warrant or make any representations
17 * regarding the use of the software or the results thereof, including but
18 * not limited to the correctness, accuracy, reliability or usefulness of
19 * the software.
20 *
21 * Permission to use this software is contingent upon your acceptance
22 * of the terms of this agreement
23 *
24 * .
25 *
26 */
27 /*******************************************
28  * PRODUCT OF PT INOVACAO - EST DEPARTMENT *
29  *******************************************/
30 
31 package gov.nist.javax.sip.header.ims;
32 
33 
34 import java.text.ParseException;
35 import javax.sip.header.Header;
36 import javax.sip.header.Parameters;
37 
38 
39 
40 
41 /**
42  * <p>P-Charging-Vector header SIP Private Header. </p>
43  *
44  *  <p> Sintax (RFC 3455): </p>
45  * <pre>
46  * P-Charging-Vector   = "P-Charging-Vector" HCOLON icid-value (SEMI charge-params)
47  * charge-params        = icid-gen-addr / orig-ioi / term-ioi / generic-param
48  * icid-value           = "icid-value" EQUAL gen-value
49  * icid-gen-addr        = "icid-generated-at" EQUAL host
50  * orig-ioi             = "orig-ioi" EQUAL gen-value
51  * term-ioi             = "term-ioi" EQUAL gen-value
52  * </pre>
53  *
54  * <p>Sintax from RFC3261: </p>
55  * <pre>
56  * generic-param       = token [ EQUAL gen-value ]
57  * gen-value           = token / host / quoted-string
58  * host                = hostname / IPv4address / Ipv6reference
59  * </pre>
60  *
61  *
62  * <p> syntax as in 3GPP TS 24.229-720 (2005-12) :
63  *
64  *    The access-network-charging-info parameter is an instance of generic-param
65  *    from the current charge-params: </p>
66  *
67  * <pre>
68  * access-network-charging-info   = (gprs-charging-info / i-wlan-charging-info / xdsl-charging-info / generic-param)
69  * gprs-charging-info          = ggsn SEMI auth-token [SEMI pdp-info-hierarchy] *(SEMI extension-param)
70  * ggsn                        = "ggsn" EQUAL gen-value
71  * pdp-info-hierarchy          = "pdp-info" EQUAL LDQUOT pdp-info *(COMMA pdp-info) RDQUOT
72  * pdp-info                    = pdp-item SEMI pdp-sig SEMI gcid [SEMI flow-id]
73  * pdp-item                    = "pdp-item" EQUAL DIGIT
74  * pdp-sig                     = "pdp-sig" EQUAL ("yes" / "no")
75  * gcid                        = "gcid" EQUAL 1*HEXDIG
76  * auth-token                  = "auth-token" EQUAL 1*HEXDIG
77  * flow-id                     = "flow-id" EQUAL "(" "{" 1*DIGIT COMMA 1*DIGIT "}" *(COMMA "{" 1*DIGIT COMMA 1*DIGIT"}")")"
78  * extension-param             = token [EQUAL token]
79  * i-wlan-charging-info        = "pdg"
80  * xdsl-charging-info          = bras SEMI auth-token [SEMI xDSL-bearer-info] *(SEMI extension-param)
81  * bras                        = "bras" EQUAL gen-value
82  * xDSL-bearer-info            = "dsl-bearer-info" EQUAL LDQUOT dsl-bearer-info *(COMMA dsl-bearer-info) RDQUOT
83  * dsl-bearer-info             = dsl-bearer-item SEMI dsl-bearer-sig SEMI dslcid [SEMI flow-id]
84  * dsl-bearer-item             = "dsl-bearer-item" EQUAL DIGIT
85  * dsl-bearer-sig              = "dsl-bearer-sig"
86  * </pre>
87  *
88  *
89  * <p>example:
90  * P-Charging-Vector: icid-value=1234bc9876e; icid-generated-at=192.0.6.8; orig-ioi=home1.net </p>
91  *
92  *
93  * <p>TODO: gen-value can be token / host / quoted-string</p>
94  * <p>TODO: add suport for the new header extensions access-network-charging-info</p>
95  *
96  * @author ALEXANDRE MIGUEL SILVA SANTOS
97  */
98 
99 
100 
101 public interface PChargingVectorHeader extends Header, Parameters {
102 
103     /**
104      * Name of PChargingVectorHeader
105      */
106     public final static String NAME = "P-Charging-Vector";
107 
108 
109     /**
110      * @return -- icid value.
111      */
getICID()112     public String getICID();
113 
114 
115     /**
116      * @param icid
117      * @throws ParseException
118      */
setICID(String icid)119     public void setICID(String icid) throws ParseException;
120 
121     /**
122      * @return -- the ICID generatedAt field.
123      */
getICIDGeneratedAt()124     public String getICIDGeneratedAt();
125 
126 
127     /**
128      * @param host -- set the icid host value.
129      *
130      * @throws ParseException -- if bad host value.
131      */
setICIDGeneratedAt(String host)132     public void setICIDGeneratedAt(String host) throws ParseException;
133 
134 
135     /**
136      *
137      * @return the originating IOI
138      */
getOriginatingIOI()139     public String getOriginatingIOI();
140 
141 
142     /**
143      * @param origIOI
144      * @throws ParseException
145      *
146      */
setOriginatingIOI(String origIOI)147     public void setOriginatingIOI(String origIOI) throws ParseException;
148 
149 
150     /**
151      * @return -- the terminating IOI field
152      */
getTerminatingIOI()153     public String getTerminatingIOI();
154 
155 
156     /**
157      * @param termIOI -- the terminating IOI field to set.
158      * @throws ParseException
159      */
setTerminatingIOI(String termIOI)160     public void setTerminatingIOI(String termIOI) throws ParseException;
161 
162 
163 
164 
165 
166 
167 }
168