Speaks the announce string.
427438
function() {
      if (!Assistive.getOption('speech')) return;
      LiveRegion.announced = true;
      MathJax.Ajax.Styles(LiveRegion.styles);
      var div = LiveRegion.Create('polite');
      document.body.appendChild(div);
      LiveRegion.Update(div, LiveRegion.ANNOUNCE);
      setTimeout(function() {document.body.removeChild(div);}, 1000);
    }
713387
@Override
  public void play(SpeechAnnouncement speechAnnouncement) {
    boolean isValidAnnouncement = speechAnnouncement != null
      && !TextUtils.isEmpty(speechAnnouncement.announcement());
    boolean canPlay = isValidAnnouncement && languageSupported && !isMuted;
    if (!canPlay) {
      return;
    }

    fireInstructionListenerIfApi14();

    HashMap<String, String> params = new HashMap<>(1);
    params.put(TextToSpeech.Engine.KEY_PARAM_UTTERANCE_ID, DEFAULT_UTTERANCE_ID);
    textToSpeech.speak(speechAnnouncement.announcement(), TextToSpeech.QUEUE_ADD, params);
  }
32351
private void deliverFoundAnnouncement(final DeviceAnnouncement announcement) {
        for (final DeviceAnnouncementListener listener : getDeviceAnnouncementListeners()) {
            SwingUtilities.invokeLater(new Runnable() {
                @Override
                public void run() {
                    try {
                        listener.deviceFound(announcement);
                    } catch (Throwable t) {
                        logger.warn("Problem delivering device found announcement to listener", t);
                    }
                }
            });
        }
    }
747088
private void announceMPStopping() {
        if (TraceComponent.isAnyTracingEnabled()
            && tc.isEntryEnabled())
            SibTr.entry(tc, "announceMPStopping");

        if (_destinationManager != null)
            _destinationManager.announceMPStopping();

        if (TraceComponent.isAnyTracingEnabled()
            && tc.isEntryEnabled())
            SibTr.exit(tc, "announceMPStopping");
    }
651269
private void deliverTempoChangedAnnouncement(final double tempo) {
        for (final MasterListener listener : getMasterListeners()) {
            try {
                listener.tempoChanged(tempo);
            } catch (Throwable t) {
                logger.warn("Problem delivering tempo changed announcement to listener", t);
            }
        }
    }
231
public function alert($string, $event)
    {
        $this->comment(str_repeat('*', strlen($string) + 12), $event);
        $this->comment('*     ' . $string . '     *', $event);
        $this->comment(str_repeat('*', strlen($string) + 12), $event);
    }
1337422
public void speak (String arg1, byte arg2)
    {
        sendRequest(SPEAK, new Object[] {
            arg1, Byte.valueOf(arg2)
        });
    }
427731
function (status) {
                if  (anouncementIds.length > 0 && anouncementIds.indexOf(that.getCurrentPlaylistId()) < 0)
                {
                  //The item after the announcement has starting buffering -> restore original volume if required
                  if (urlOptions && urlOptions.volume) {
                    that._client.setVolumePromise(currentVolume);
                    urlOptions = undefined; //So we not set it again on every status update
                  }

                  if (that.getStatus().playerState != "BUFFERING") {
                    //The item after the announcement has starting playing -> remove announcement from list
                    log.info ("%s - Resumed after announcement", that._name);
                    that.removeFromPlaylistPromise(anouncementIds);
                    anouncementIds = [];
                    //Anouncement ended
                    return resolve(url);
                  }

                }

                if
                (
                  anouncementIds.length === 0 /*Already completed announcement*/ &&
                  (
                    //Did we insert a chunk?
                    chunkItemIds.length === 0 ||
                    //Next item started playing ?
                    (nextItem && that.getCurrentPlaylistId() == nextItem.itemId && that.getStatus().playerState != "BUFFERING")
                  )
                )
                {
                  //The remaining current item we just inserted has starting playing -> remove
                  log.info ("%s - Back to regular playlist", that._name);
                  if (chunkItemIds.length > 0)
                    that.removeFromPlaylistPromise(chunkItemIds);

                  //We are done
                  that.removeListener(that.EVENT_STATUS, resumeAfterAnnouncement);
                  return;
                }

                //Sanity check - if all items disapear then this means that a new playlist was loaded
                let idsToCheck=anouncementIds.concat(chunkItemIds);
                let allGone = true;

                for (let i in idsToCheck) {
                  if (that._playlist.getItemWithId(idsToCheck[i]) != undefined)
                    allGone = false;
                    break;
                }
                if (allGone) {
                  log.warn("%s - remaining item to play after announcement not found in the playlist -> remove status handled", that._name);
                  that.removeListener(that.EVENT_STATUS, resumeAfterAnnouncement);
                  log.debug("%s - Player status:\n%s",that._name, util.inspect(that._status,{depth:null, colors:true}))
                }

                //Not the status update we are waiting for
              }
531911
def insertAnnouncement(self, announcement):
        
        url = announcement.get('url', None)
        try:
            peers.Peer(url)
        except:
            raise exceptions.BadUrlException(url)
        try:
            # TODO get more details about the user agent
            models.Announcement.create(
                url=announcement.get('url'),
                attributes=json.dumps(announcement.get('attributes', {})),
                remote_addr=announcement.get('remote_addr', None),
                user_agent=announcement.get('user_agent', None))
        except Exception as e:
            raise exceptions.RepoManagerException(e)
732628
public static ZMsg newStringMsg(String... strings)
    {
        ZMsg msg = new ZMsg();
        for (String data : strings) {
            msg.addString(data);
        }
        return msg;
    }
821011
private void setCurrentItemShowing(int index, boolean animateCircle, boolean delayLabelAnimate,
            boolean announce) {
        mTimePicker.setCurrentItemShowing(index, animateCircle);

        TextView labelToAnimate;
        switch(index) {
            case HOUR_INDEX:
                int hours = mTimePicker.getHours();
                if (!mIs24HourMode) {
                    hours = hours % 12;
                }
                mTimePicker.setContentDescription(mHourPickerDescription + ": " + hours);
                if (announce) {
                    Utils.tryAccessibilityAnnounce(mTimePicker, mSelectHours);
                }
                labelToAnimate = mHourView;
                break;
            case MINUTE_INDEX:
                int minutes = mTimePicker.getMinutes();
                mTimePicker.setContentDescription(mMinutePickerDescription + ": " + minutes);
                if (announce) {
                    Utils.tryAccessibilityAnnounce(mTimePicker, mSelectMinutes);
                }
                labelToAnimate = mMinuteView;
                break;
            default:
                int seconds = mTimePicker.getSeconds();
                mTimePicker.setContentDescription(mSecondPickerDescription + ": " + seconds);
                if (announce) {
                    Utils.tryAccessibilityAnnounce(mTimePicker, mSelectSeconds);
                }
                labelToAnimate = mSecondView;
        }

        int hourColor = (index == HOUR_INDEX) ? mSelectedColor : mUnselectedColor;
        int minuteColor = (index == MINUTE_INDEX) ? mSelectedColor : mUnselectedColor;
        int secondColor = (index == SECOND_INDEX) ? mSelectedColor : mUnselectedColor;
        mHourView.setTextColor(hourColor);
        mMinuteView.setTextColor(minuteColor);
        mSecondView.setTextColor(secondColor);

        ObjectAnimator pulseAnimator = Utils.getPulseAnimator(labelToAnimate, 0.85f, 1.1f);
        if (delayLabelAnimate) {
            pulseAnimator.setStartDelay(PULSE_ANIMATOR_DELAY);
        }
        pulseAnimator.start();
    }
1370631
def on_chanmsg(self, from_, channel, message):
        
        if message == 'hello':
            self.privmsg(channel, 'Hello, %s!' % from_[0])
            print('%s said hello!' % from_[0])
        elif message == '!quit':
            self.quit('Bye!')
606128
function speakIt({ action }) {
    const { toSpeak } = action.payload

    // Remember: unlike Promises, which share a similar construction,
    // the observable function is not run until the Observable recieves
    // a subscribe() call.
    return new Observable(observer => {
      try {
        const say = require("say")
        say.speak(toSpeak, null, null, () => {
          observer.complete()
        })

        // An Observable allows for cancellation by returning a
        // cancellation function
        return () => {
          say.stop()
        }
      } catch (error) {
        log("-- speech synthesis not available --")
        observer.error()
      }
    })
  }
306298
public static void info(String message) {
        if (Boolean.getBoolean("visibleassertions.silence")) {
            return;
        }

        System.out.println("        " + white(bright(INFO_MARK + " " + message)));
    }
29813
private void notifyListeners() {
        WriterListener[] writerListeners;
        synchronized (listeners) {
            writerListeners = new WriterListener[listeners.size()];
            listeners.toArray(writerListeners);
        }
        String str = stringBuilder.toString();
        stringBuilder.setLength(0);
        for (WriterListener writerListener : writerListeners) {
            writerListener.write(str);
        }
    }
436218
public void deliverTell (BodyObject target, UserMessage message)
    {
        SpeakUtil.sendMessage(target, message);

        // note that the teller "heard" what they said
        SpeakUtil.noteMessage(target, message.speaker, message);
    }
922890
public void announceMPStarted(
      int startMode,
      JsMessagingEngine me) throws SIResourceException, SIException
  {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.entry(
        tc,
        "announceMPStarted",
        new Object[] {
            startMode,
            me });

    // Drive mpStarted against the associated MQLink object
    if(_mqLinkObject != null)
      _mqLinkObject.mpStarted(startMode, me);

    
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.exit(tc, "announceMPStarted");
  }