1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-02-15 04:42:04 +00:00

add comments for the RTMP packet fields, NULL or never NULL. 2.0.5

This commit is contained in:
winlin 2014-10-24 10:58:06 +08:00
parent 1bfc238fec
commit b65dfd718a
2 changed files with 27 additions and 1 deletions

View file

@ -31,7 +31,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
// current release version // current release version
#define VERSION_MAJOR "2" #define VERSION_MAJOR "2"
#define VERSION_MINOR "0" #define VERSION_MINOR "0"
#define VERSION_REVISION "4" #define VERSION_REVISION "5"
#define RTMP_SIG_SRS_VERSION VERSION_MAJOR"."VERSION_MINOR"."VERSION_REVISION #define RTMP_SIG_SRS_VERSION VERSION_MAJOR"."VERSION_MINOR"."VERSION_REVISION
// server info. // server info.
#define RTMP_SIG_SRS_KEY "SRS" #define RTMP_SIG_SRS_KEY "SRS"

View file

@ -572,10 +572,12 @@ public:
* Command information object which has the name-value pairs. * Command information object which has the name-value pairs.
* @remark: alloc in packet constructor, user can directly use it, * @remark: alloc in packet constructor, user can directly use it,
* user should never alloc it again which will cause memory leak. * user should never alloc it again which will cause memory leak.
* @remark, never be NULL.
*/ */
SrsAmf0Object* command_object; SrsAmf0Object* command_object;
/** /**
* Any optional information * Any optional information
* @remark, optional, init to and maybe NULL.
*/ */
SrsAmf0Object* args; SrsAmf0Object* args;
public: public:
@ -608,11 +610,13 @@ public:
double transaction_id; double transaction_id;
/** /**
* Name-value pairs that describe the properties(fmsver etc.) of the connection. * Name-value pairs that describe the properties(fmsver etc.) of the connection.
* @remark, never be NULL.
*/ */
SrsAmf0Object* props; SrsAmf0Object* props;
/** /**
* Name-value pairs that describe the response from|the server. code, * Name-value pairs that describe the response from|the server. code,
* level, description are names of few among such information. * level, description are names of few among such information.
* @remark, never be NULL.
*/ */
SrsAmf0Object* info; SrsAmf0Object* info;
public: public:
@ -650,10 +654,12 @@ public:
/** /**
* If there exists any command info this * If there exists any command info this
* is set, else this is set to null type. * is set, else this is set to null type.
* @remark, optional, init to and maybe NULL.
*/ */
SrsAmf0Any* command_object; SrsAmf0Any* command_object;
/** /**
* Any optional arguments to be provided * Any optional arguments to be provided
* @remark, optional, init to and maybe NULL.
*/ */
SrsAmf0Any* arguments; SrsAmf0Any* arguments;
public: public:
@ -686,10 +692,12 @@ public:
double transaction_id; double transaction_id;
/** /**
* If there exists any command info this is set, else this is set to null type. * If there exists any command info this is set, else this is set to null type.
* @remark, optional, init to and maybe NULL.
*/ */
SrsAmf0Any* command_object; SrsAmf0Any* command_object;
/** /**
* Response from the method that was called. * Response from the method that was called.
* @remark, optional, init to and maybe NULL.
*/ */
SrsAmf0Any* response; SrsAmf0Any* response;
public: public:
@ -724,6 +732,7 @@ public:
double transaction_id; double transaction_id;
/** /**
* If there exists any command info this is set, else this is set to null type. * If there exists any command info this is set, else this is set to null type.
* @remark, never be NULL, an AMF0 null instance.
*/ */
SrsAmf0Any* command_object; // null SrsAmf0Any* command_object; // null
public: public:
@ -756,6 +765,7 @@ public:
double transaction_id; double transaction_id;
/** /**
* If there exists any command info this is set, else this is set to null type. * If there exists any command info this is set, else this is set to null type.
* @remark, never be NULL, an AMF0 null instance.
*/ */
SrsAmf0Any* command_object; // null SrsAmf0Any* command_object; // null
/** /**
@ -793,6 +803,7 @@ public:
double transaction_id; double transaction_id;
/** /**
* Command information object does not exist. Set to null type. * Command information object does not exist. Set to null type.
* @remark, never be NULL, an AMF0 null instance.
*/ */
SrsAmf0Any* command_object; // null SrsAmf0Any* command_object; // null
public: public:
@ -819,6 +830,7 @@ public:
double transaction_id; double transaction_id;
/** /**
* If there exists any command info this is set, else this is set to null type. * If there exists any command info this is set, else this is set to null type.
* @remark, never be NULL, an AMF0 null instance.
*/ */
SrsAmf0Any* command_object; // null SrsAmf0Any* command_object; // null
/** /**
@ -859,10 +871,12 @@ public:
double transaction_id; double transaction_id;
/** /**
* If there exists any command info this is set, else this is set to null type. * If there exists any command info this is set, else this is set to null type.
* @remark, never be NULL, an AMF0 null instance.
*/ */
SrsAmf0Any* command_object; // null SrsAmf0Any* command_object; // null
/** /**
* the optional args, set to undefined. * the optional args, set to undefined.
* @remark, never be NULL, an AMF0 undefined instance.
*/ */
SrsAmf0Any* args; // undefined SrsAmf0Any* args; // undefined
public: public:
@ -900,6 +914,7 @@ public:
double transaction_id; double transaction_id;
/** /**
* Command information object does not exist. Set to null type. * Command information object does not exist. Set to null type.
* @remark, never be NULL, an AMF0 null instance.
*/ */
SrsAmf0Any* command_object; // null SrsAmf0Any* command_object; // null
/** /**
@ -952,6 +967,7 @@ public:
double transaction_id; double transaction_id;
/** /**
* Command information object does not exist. Set to null type. * Command information object does not exist. Set to null type.
* @remark, never be NULL, an AMF0 null instance.
*/ */
SrsAmf0Any* command_object; // null SrsAmf0Any* command_object; // null
/** /**
@ -990,6 +1006,7 @@ public:
double transaction_id; double transaction_id;
/** /**
* Command information does not exist. Set to null type. * Command information does not exist. Set to null type.
* @remark, never be NULL, an AMF0 null instance.
*/ */
SrsAmf0Any* command_object; // null SrsAmf0Any* command_object; // null
/** /**
@ -1069,12 +1086,14 @@ public:
double transaction_id; double transaction_id;
/** /**
* Command information does not exist. Set to null type. * Command information does not exist. Set to null type.
* @remark, never be NULL, an AMF0 null instance.
*/ */
SrsAmf0Any* command_object; // null SrsAmf0Any* command_object; // null
/** /**
* If the play command is successful, the client receives OnStatus message from * If the play command is successful, the client receives OnStatus message from
* server which is NetStream.Play.Start. If the specified stream is not found, * server which is NetStream.Play.Start. If the specified stream is not found,
* NetStream.Play.StreamNotFound is received. * NetStream.Play.StreamNotFound is received.
* @remark, never be NULL, an AMF0 object instance.
*/ */
SrsAmf0Object* desc; SrsAmf0Object* desc;
public: public:
@ -1105,6 +1124,7 @@ public:
double transaction_id; double transaction_id;
/** /**
* Command information does not exist. Set to null type. * Command information does not exist. Set to null type.
* @remark, never be NULL, an AMF0 null instance.
*/ */
SrsAmf0Any* args; // null SrsAmf0Any* args; // null
public: public:
@ -1136,11 +1156,13 @@ public:
double transaction_id; double transaction_id;
/** /**
* Command information does not exist. Set to null type. * Command information does not exist. Set to null type.
* @remark, never be NULL, an AMF0 null instance.
*/ */
SrsAmf0Any* args; // null SrsAmf0Any* args; // null
/** /**
* Name-value pairs that describe the response from the server. * Name-value pairs that describe the response from the server.
* code,level, description are names of few among such information. * code,level, description are names of few among such information.
* @remark, never be NULL, an AMF0 object instance.
*/ */
SrsAmf0Object* data; SrsAmf0Object* data;
public: public:
@ -1176,11 +1198,13 @@ public:
double transaction_id; double transaction_id;
/** /**
* Command information does not exist. Set to null type. * Command information does not exist. Set to null type.
* @remark, never be NULL, an AMF0 null instance.
*/ */
SrsAmf0Any* args; // null SrsAmf0Any* args; // null
/** /**
* Name-value pairs that describe the response from the server. * Name-value pairs that describe the response from the server.
* code,level, description are names of few among such information. * code,level, description are names of few among such information.
* @remark, never be NULL, an AMF0 object instance.
*/ */
SrsAmf0Object* data; SrsAmf0Object* data;
public: public:
@ -1238,6 +1262,7 @@ public:
/** /**
* Name-value pairs that describe the response from the server. * Name-value pairs that describe the response from the server.
* code, are names of few among such information. * code, are names of few among such information.
* @remark, never be NULL, an AMF0 object instance.
*/ */
SrsAmf0Object* data; SrsAmf0Object* data;
public: public:
@ -1301,6 +1326,7 @@ public:
std::string name; std::string name;
/** /**
* Metadata of stream. * Metadata of stream.
* @remark, never be NULL, an AMF0 object instance.
*/ */
SrsAmf0Object* metadata; SrsAmf0Object* metadata;
public: public: