public void onEvent(javax.media.mscontrol.join.JoinEvent event) {

      MediaGroup mg = (MediaGroup) event.getThisJoinable();
      if (event.isSuccessful()) {

        if (JoinEvent.JOINED == event.getEventType()) {
          // NC Joined to MG

          try {
            Player player = mg.getPlayer();
            player.addListener(new PlayerListener());

            URI prompt = URI.create(WELCOME_MSG);

            player.play(prompt, null, null);

          } catch (MsControlException e) {
            logger.error(e);
          }
        } else if (JoinEvent.UNJOINED == event.getEventType()) {
          if (logger.isDebugEnabled()) {
            logger.debug("Un-Joined MG and NC");
          }
        }

      } else {
        logger.error("Joining of MG and NC failed");
      }
    }
 /* (non-Javadoc)
  * @see org.mobicents.servlet.sip.conference.ConferenceLeg#join(org.mobicents.servlet.sip.conference.Conference)
  */
 @SuppressWarnings("serial")
 public void join(final Conference conference) {
   join(conference, Direction.DUPLEX);
   try {
     Thread.sleep(800);
     mg.getPlayer().play(URI.create(url), null, null);
   } catch (Exception e) {
     logger.error("Error", e);
   }
 }