Java Doc for MediaDescriptionImpl.java in  » 6.0-JDK-Modules » j2me » gov » nist » javax » sdp » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » 6.0 JDK Modules » j2me » gov.nist.javax.sdp 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   gov.nist.javax.sdp.MediaDescriptionImpl

MediaDescriptionImpl
public class MediaDescriptionImpl (Code)
Field implementation of Media Description interface.
version:
   JSR141-PUBLIC-REVIEW (subject to change).
version:
   This code is in the public domain.


Field Summary
protected  VectorattributeFields
     Connection attributes.
protected  VectorbandwidthFields
     Vector of bandwidths.
protected  ConnectionFieldconnectionField
     Current connection.
protected  InformationFieldinformationField
     Extra information field.
protected  KeyFieldkeyField
     Key field.
protected  MediaFieldmediaField
     Media type field.

Constructor Summary
public  MediaDescriptionImpl()
     Default constructor.

Method Summary
protected  voidaddAttribute(AttributeField af)
     Adds a new attirbute to the list.
public  voidaddBandwidthField(BandwidthField b)
     Sets the bandwidth field member.
public  voidaddDynamicPayloads(Vector payloadNames, Vector payloadValues)
     Adds dynamic media types to the description.
public  Stringencode()
     Encodes to a canonical form.
public  StringgetAttribute(String name)
     Returns the value of the specified attribute.
public  VectorgetAttributeFields()
     Gets the attributes filed.
public  VectorgetAttributes(boolean create)
     Returns the set of attributes for this Description as a Vector of Attribute objects in the order they were parsed.
public  intgetBandwidth(String name)
     Returns the integer value of the specified bandwidth name.
public  VectorgetBandwidths(boolean create)
     Returns the Bandwidth of the specified type.
public  ConnectionFieldgetConnection()
     Returns the connection information associated with this object.
public  ConnectionFieldgetConnectionField()
    
public  InformationFieldgetInfo()
     Returns value of the info field (i=) of this object.
public  InformationFieldgetInformationField()
     Gets the information field.
public  KeyFieldgetKey()
     Returns the key data.
public  KeyFieldgetKeyField()
     Gets the key field.
public  MediaFieldgetMedia()
     Returns the Media field of the description.
public  MediaFieldgetMediaField()
    
public  VectorgetMimeParameters()
     Returns a Vector containing a string of parameters for each of the codecs in this description.

A parameter string is computed for each codec.

The parameter string is computed in the following fashion.

The rate is extracted from the rtpmap or static data.

The number of channels is extracted from the rtpmap or static data.

The ptime is extracted from the ptime attribute.

The maxptime is extracted from the maxptime attribute.

Any additional parameters are extracted from the ftmp attribute.
throws:
  SdpException - if there is a problem extracting the parameters.

public  VectorgetMimeTypes()
     Returns a Vector containing a string indicating the MIME type for each of the codecs in this description.

A MIME value is computed for each codec in the media description.

The MIME type is computed in the following fashion: The type is the mediaType from the media field. The subType is determined by the protocol.

The result is computed as the string of the form:

 type + '/' + subType
 
The subType portion is computed in the following fashion. RTP/AVP the subType is returned as the codec name.
protected  booleanhasAttribute(String name)
     Checks if named attribute exists.
public  voidremoveAttribute(String name)
     Removes the attribute specified by the value parameter.
public  voidremoveBandwidth(String name)
     Removes the specified bandwidth type.
public  voidsetAttribute(String name, String value)
    
public  voidsetAttributeFields(Vector a)
     Sets the attribute fields member.
public  voidsetAttributes(Vector attributes)
     Adds the specified Attribute to this Description object.
public  voidsetBandwidth(String name, int value)
     Sets the value of the specified bandwidth type.
public  voidsetBandwidths(Vector bandwidths)
     Sets the value of the Bandwidth with the specified type.
public  voidsetConnection(ConnectionField conn)
     Sets the connection data for this entity.
public  voidsetConnectionField(ConnectionField c)
     Sets the connection field member.
public  voidsetInfo(InformationField i)
     Sets the i= field of this object.
public  voidsetInformationField(InformationField i)
     Sets the information field member.
public  voidsetKey(KeyField key)
     Sets encryption key information.
public  voidsetKeyField(KeyField k)
     Sets the key field member.
public  voidsetMedia(MediaField media)
     Sets the Media field of the description.
public  voidsetMediaField(MediaField m)
     Sets the media field member.
public  StringtoString()
     Returns encoded text.

Field Detail
attributeFields
protected Vector attributeFields(Code)
Connection attributes.



bandwidthFields
protected Vector bandwidthFields(Code)
Vector of bandwidths.



connectionField
protected ConnectionField connectionField(Code)
Current connection.



informationField
protected InformationField informationField(Code)
Extra information field.



keyField
protected KeyField keyField(Code)
Key field.



mediaField
protected MediaField mediaField(Code)
Media type field.




Constructor Detail
MediaDescriptionImpl
public MediaDescriptionImpl()(Code)
Default constructor.




Method Detail
addAttribute
protected void addAttribute(AttributeField af)(Code)
Adds a new attirbute to the list.
Parameters:
  af - the attribute field to be processed



addBandwidthField
public void addBandwidthField(BandwidthField b)(Code)
Sets the bandwidth field member.
Parameters:
  b - the new bandwidth field



addDynamicPayloads
public void addDynamicPayloads(Vector payloadNames, Vector payloadValues) throws SdpException(Code)
Adds dynamic media types to the description.
Parameters:
  payloadNames - a Vector of String - each one the name of a dynamic payload to be added (usually an integer largerthan SdpConstants.AVP_DYNAMIC_MIN).
Parameters:
  payloadValues - a Vector of String - each contains the value describing the correlated dynamic payloads to be added
throws:
  SdpException - if either vector is null or empty.if the vector sizes are unequal.



encode
public String encode()(Code)
Encodes to a canonical form. encoded string of object contents
since:
   v1.0



getAttribute
public String getAttribute(String name) throws SdpParseException(Code)
Returns the value of the specified attribute.
Parameters:
  name - the name of the attribute.
throws:
  SdpParseException - the value of the named attribute



getAttributeFields
public Vector getAttributeFields()(Code)
Gets the attributes filed. the vector of attributes



getAttributes
public Vector getAttributes(boolean create)(Code)
Returns the set of attributes for this Description as a Vector of Attribute objects in the order they were parsed.
Parameters:
  create - specifies whether to return null or a new empty Vector in caseno attributes exists for this Description attributes for this Description



getBandwidth
public int getBandwidth(String name) throws SdpParseException(Code)
Returns the integer value of the specified bandwidth name.
Parameters:
  name - the name of the bandwidth type.
throws:
  SdpParseException - if a parsing error occurs the value of the named bandwidth



getBandwidths
public Vector getBandwidths(boolean create)(Code)
Returns the Bandwidth of the specified type.
Parameters:
  create - type of the Bandwidth to return the Bandwidth or null if undefined



getConnection
public ConnectionField getConnection()(Code)
Returns the connection information associated with this object. This may be null for SessionDescriptions if all Media objects have a connection object and may be null for Media objects if the corresponding session connection is non-null. connection



getConnectionField
public ConnectionField getConnectionField()(Code)
Gets the connection filed the connection firld



getInfo
public InformationField getInfo()(Code)
Returns value of the info field (i=) of this object. value of the info field (i=) of this object.



getInformationField
public InformationField getInformationField()(Code)
Gets the information field. the information field



getKey
public KeyField getKey()(Code)
Returns the key data. the key data.



getKeyField
public KeyField getKeyField()(Code)
Gets the key field. the key field



getMedia
public MediaField getMedia()(Code)
Returns the Media field of the description. the Media field of the description.



getMediaField
public MediaField getMediaField()(Code)
Gets the media field the media field



getMimeParameters
public Vector getMimeParameters() throws SdpException(Code)
Returns a Vector containing a string of parameters for each of the codecs in this description.

A parameter string is computed for each codec.

The parameter string is computed in the following fashion.

The rate is extracted from the rtpmap or static data.

The number of channels is extracted from the rtpmap or static data.

The ptime is extracted from the ptime attribute.

The maxptime is extracted from the maxptime attribute.

Any additional parameters are extracted from the ftmp attribute.
throws:
  SdpException - if there is a problem extracting the parameters. a Vector containing a string of parameters for each of the codecs in this description.




getMimeTypes
public Vector getMimeTypes() throws SdpException(Code)
Returns a Vector containing a string indicating the MIME type for each of the codecs in this description.

A MIME value is computed for each codec in the media description.

The MIME type is computed in the following fashion: The type is the mediaType from the media field. The subType is determined by the protocol.

The result is computed as the string of the form:

 type + '/' + subType
 
The subType portion is computed in the following fashion. RTP/AVP the subType is returned as the codec name. This will either be extracted from the rtpmap attribute or computed. other the protocol is returned as the subType.

If the protocol is RTP/AVP and the rtpmap attribute for a codec is absent, then the codec name will be computed in the following fashion. String indexed in table SdpConstants.avpTypeNames if the value is an int greater than or equal to 0 and less than AVP_DEFINED_STATIC_MAX, and has been assigned a value. SdpConstant.RESERVED if the value is an int greater than or equal to 0 and less than AVP_DEFINED_STATIC_MAX, and has not been assigned a value. SdpConstant.UNASSIGNED An int greater than or equal to AVP_DEFINED_STATIC_MAX and less than AVP_DYNAMIC_MIN - currently unassigned. SdpConstant.DYNAMIC Any int less than 0 or greater than or equal to AVP_DYNAMIC_MIN
throws:
  SdpException - if there is a problem extracting the parameters. a Vector containing a string indicating the MIME type for each of the codecs in this description




hasAttribute
protected boolean hasAttribute(String name)(Code)
Checks if named attribute exists.
Parameters:
  name - the attribute to check true is attribute is found



removeAttribute
public void removeAttribute(String name)(Code)
Removes the attribute specified by the value parameter.
Parameters:
  name - the name of the attribute.



removeBandwidth
public void removeBandwidth(String name)(Code)
Removes the specified bandwidth type.
Parameters:
  name - the name of the bandwidth type.



setAttribute
public void setAttribute(String name, String value) throws SdpException(Code)
Sets the value of the specified attribute
Parameters:
  name - the name of the attribute.
Parameters:
  value - the value of the named attribute.
throws:
  SdpException - if the parameters are null



setAttributeFields
public void setAttributeFields(Vector a)(Code)
Sets the attribute fields member.
Parameters:
  a - the new vector of attributes



setAttributes
public void setAttributes(Vector attributes) throws SdpException(Code)
Adds the specified Attribute to this Description object.
Parameters:
  attributes - the attribute to add
throws:
  SdpException - if the attributes is null



setBandwidth
public void setBandwidth(String name, int value) throws SdpException(Code)
Sets the value of the specified bandwidth type.
Parameters:
  name - the name of the bandwidth type.
Parameters:
  value - the value of the named bandwidth type.
throws:
  SdpException - if the name is null



setBandwidths
public void setBandwidths(Vector bandwidths) throws SdpException(Code)
Sets the value of the Bandwidth with the specified type.
Parameters:
  bandwidths - type of the Bandwidth object whose value is requested
throws:
  SdpException - if vector is null



setConnection
public void setConnection(ConnectionField conn) throws SdpException(Code)
Sets the connection data for this entity.
Parameters:
  conn - to set
throws:
  SdpException - if the connexion is null



setConnectionField
public void setConnectionField(ConnectionField c)(Code)
Sets the connection field member.
Parameters:
  c - the new connection field



setInfo
public void setInfo(InformationField i) throws SdpException(Code)
Sets the i= field of this object.
Parameters:
  i - to set
throws:
  SdpException - if the info is null



setInformationField
public void setInformationField(InformationField i)(Code)
Sets the information field member.
Parameters:
  i - the new information filed



setKey
public void setKey(KeyField key) throws SdpException(Code)
Sets encryption key information. This consists of a method and an encryption key included inline.
Parameters:
  key - the encryption key data; depending on method may be null
throws:
  SdpException - if the key is null



setKeyField
public void setKeyField(KeyField k)(Code)
Sets the key field member.
Parameters:
  k - the new key field



setMedia
public void setMedia(MediaField media) throws SdpException(Code)
Sets the Media field of the description.
Parameters:
  media - to set
throws:
  SdpException - if the media field is null



setMediaField
public void setMediaField(MediaField m)(Code)
Sets the media field member.
Parameters:
  m - the new media field



toString
public String toString()(Code)
Returns encoded text. encoded string of object contents



Methods inherited from java.lang.Object
public boolean equals(Object obj)(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.