java.lang.IllegalStateException.toString()方法的使用及代码示例

x33g5p2x  于2022-01-16 转载在 其他  
字(5.8k)|赞(0)|评价(0)|浏览(124)

本文整理了Java中java.lang.IllegalStateException.toString()方法的一些代码示例,展示了IllegalStateException.toString()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。IllegalStateException.toString()方法的具体详情如下:
包路径:java.lang.IllegalStateException
类名称:IllegalStateException
方法名:toString

IllegalStateException.toString介绍

暂无

代码示例

代码示例来源:origin: JZ-Darkal/AndroidHttpCapture

public void run() {
    Toast.makeText(MyVpnService.this, "Cannot establish VPN (" + e.toString() + ")",
        Toast.LENGTH_LONG).show();
  }
});

代码示例来源:origin: chewiebug/GCViewer

private void printDoubleData(String name, DoubleData data) {
  try {
    System.out.println(name + " (n, avg, stddev, min, max):\t" + data.getN() + "\t" + data.average() + "\t" + data.standardDeviation() + "\t" + data.getMin() + "\t" + data.getMax());
  } catch (IllegalStateException e) {
    System.out.println(name + "\t" + e.toString());
  }
}

代码示例来源:origin: chewiebug/GCViewer

private void printIntData(String name, IntData data) {
  try {
    System.out.println(name + " (n, avg, stddev, min, max):\t" + data.getN() + "\t" + data.average() + "\t" + data.standardDeviation() + "\t" + data.getMin() + "\t" + data.getMax());
  } catch (IllegalStateException e) {
    System.out.println(name + "\t" + e.toString());
  }
}

代码示例来源:origin: robovm/robovm

} catch (IllegalStateException  e) {
  throw new NoSuchAlgorithmException(e.toString());

代码示例来源:origin: robovm/robovm

} catch (IllegalStateException  e) {
  throw new NoSuchAlgorithmException(e.toString());

代码示例来源:origin: JohnPersano/SuperToasts

Log.e(getClass().getName(), illegalStateException.toString());

代码示例来源:origin: apache/nifi

logger.error("Failed to change Scheduled State of {} from {} to {} due to {}", taskNode, taskNode.getScheduledState().name(), dto.getState(), ise.toString());
logger.error("", ise);
    "Failed to change Scheduled State of " + taskNode + " from " + taskNode.getScheduledState().name() + " to " + dto.getState() + " due to " + ise.toString()));
    "Failed to change Scheduled State of " + taskNode + " from " + taskNode.getScheduledState().name() + " to " + dto.getState() + " due to " + ise.toString()));

代码示例来源:origin: google/santa-tracker-android

@Override
public void start() {
  try {
    currentPlayer.start();
  } catch (IllegalStateException e) {
    SantaLog.w(TAG, "start() failed: " + e.toString());
  }
}

代码示例来源:origin: google/santa-tracker-android

@Override
public void start() {
  try {
    mediaPlayer.start();
  } catch (IllegalStateException e) {
    SantaLog.w(TAG, "start() failed: " + e.toString());
  }
}

代码示例来源:origin: google/santa-tracker-android

@Override
public void pause() {
  try {
    mediaPlayer.pause();
  } catch (IllegalStateException e) {
    SantaLog.w(TAG, "pause() failed: " + e.toString());
  }
}

代码示例来源:origin: google/santa-tracker-android

@Override
  public void release() {
    try {
      mediaPlayer.release();
    } catch (IllegalStateException e) {
      SantaLog.w(TAG, "release() failed: " + e.toString());
    }
  }
}

代码示例来源:origin: google/santa-tracker-android

@Override
public void setNextMediaPlayer(MediaPlayer next) {
  try {
    mediaPlayer.setNextMediaPlayer(next);
  } catch (IllegalStateException e) {
    SantaLog.w(TAG, "setNextMediaPlayer() failed: " + e.toString());
  }
}

代码示例来源:origin: google/santa-tracker-android

@Override
public void unmute() {
  try {
    mediaPlayer.setVolume(volume, volume);
  } catch (IllegalStateException e) {
    SantaLog.w(TAG, "unmute() failed: " + e.toString());
  }
}

代码示例来源:origin: google/santa-tracker-android

@Override
public void setVolume(float volume) {
  this.volume = volume;
  try {
    mediaPlayer.setVolume(volume, volume);
  } catch (IllegalStateException e) {
    SantaLog.w(TAG, "setVolume() failed: " + e.toString());
  }
}

代码示例来源:origin: google/santa-tracker-android

@Override
public void mute() {
  try {
    mediaPlayer.setVolume(0, 0);
  } catch (IllegalStateException e) {
    SantaLog.w(TAG, "mute() failed: " + e.toString());
  }
}

代码示例来源:origin: weexteam/weex-hackernews

private void superSetCurrentItem(int item, boolean smooth) {
 try {
  super.setCurrentItem(item, smooth);
 } catch (IllegalStateException e) {
  WXLogUtils.e(e.toString());
  if (getAdapter() != null) {
   getAdapter().notifyDataSetChanged();
   super.setCurrentItem(item, smooth);
  }
 }
}

代码示例来源:origin: apache/nifi

logger.error("Failed to change Scheduled State of {} from {} to {} due to {}", procNode, procNode.getScheduledState().name(), dto.getState(), ise.toString());
logger.error("", ise);
    "Failed to change Scheduled State of " + procNode + " from " + procNode.getScheduledState().name() + " to " + dto.getState() + " due to " + ise.toString()));
    "Failed to change Scheduled State of " + procNode + " from " + procNode.getScheduledState().name() + " to " + dto.getState() + " due to " + ise.toString()));

代码示例来源:origin: google/santa-tracker-android

public void playLongSoundsInSequence(int[] soundIds) {
  for (int i = 0; i < soundIds.length; i++) {
    if (isPlayingLongSound(soundIds[i])) {
      // Don't try to play long sounds which are already playing.
      return;
    }
  }
  try {
    DoodleMediaPlayer[] sounds = new DoodleMediaPlayer[soundIds.length];
    for (int i = 0; i < soundIds.length; i++) {
      sounds[i] = mediaPlayerMap.get(soundIds[i]);
      if (sounds[i] == null) {
        return;
      }
      if (i > 0) {
        sounds[i - 1].setNextMediaPlayer(sounds[i].getMediaPlayer());
      }
    }
    sounds[0].start();
  } catch (IllegalStateException e) {
    SantaLog.d(TAG, "playLongSoundsInSequence() failed: " + e.toString());
  }
}

代码示例来源:origin: weexteam/weex-hackernews

@Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
 try {
  super.onMeasure(widthMeasureSpec, heightMeasureSpec);
 } catch (IllegalStateException e) {
  WXLogUtils.e(e.toString());
  if (getAdapter() != null) {
   getAdapter().notifyDataSetChanged();
   super.onMeasure(widthMeasureSpec, heightMeasureSpec);
  }
 }
}

代码示例来源:origin: com.athaydes.protobuf/protobuf-tcp-rpc

void run() {
  VarIntReader reader = new VarIntReader();
  try {
    clientSocket.read(reader.buffer(), 5, TimeUnit.SECONDS, reader, this);
  } catch (IllegalStateException e) {
    log.debug("Unable to continue listening to client socket due to {}", e.toString());
    closeQuietly(clientSocket);
  }
}

相关文章