How to grans privilege to Oracle advance queue to be enqueued or dequeued

BEGIN
 -- we are given enqueue right to SchemaNameB to be able to enque SchemaName.QueueTableA
 sys.dbms_aqadm.Grant_queue_privilege ('ENQUEUE', 'SchemaName.QueueTableA', 'SchemaNameB', TRUE);
 -- we are given dequeue right to DBUserName to be able to dequeue message from queue
 sys.dbms_aqadm.Grant_queue_privilege ('DEQUEUE', 'SchemaName.QueueTableName' , 'DBUserName', FALSE);
END;

For more information please visit https://docs.oracle.com/database/121/ARPLS/d_aqadm.htm#ARPLS117