javax.swing.JTextArea.write()方法的使用及代码示例

x33g5p2x  于2022-01-21 转载在 其他  
字(2.5k)|赞(0)|评价(0)|浏览(152)

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

JTextArea.write介绍

暂无

代码示例

代码示例来源:origin: pentaho/mondrian

Writer cdataTextAreaStr = new StringWriter();
try {
  cdataTextArea.write(cdataTextAreaStr);
} catch (Exception ex) {

代码示例来源:origin: pentaho/mondrian

Writer cdataTextAreaStr = new StringWriter();
try {
  cdataTextArea.write(cdataTextAreaStr);
} catch (Exception ex) {

代码示例来源:origin: stackoverflow.com

JTextArea jArea=new JTextArea();
//do something............
BufferedWriter fileOut = new BufferedWriter(new FileWriter(yourFile));
jArea.write(fileOut);

代码示例来源:origin: stackoverflow.com

JTextArea textArea = new JTextArea(2, 20);
FileWriter logg =new FileWriter("logsheet.txt",true);
textArea.write(logg);

代码示例来源:origin: us.ihmc/IHMCHumanoidBehaviors

private void saveFile(String fileName)
{
 try
 {
   FileWriter w = new FileWriter(fileName);
   textArea.write(w);
   w.close();
   currentFile = fileName;
   changed = false;
   Save.setEnabled(false);
 }
 catch (IOException e)
 {
 }
}

代码示例来源:origin: us.ihmc/ihmc-humanoid-behaviors

private void saveFile(String fileName)
{
 try
 {
   FileWriter w = new FileWriter(fileName);
   textArea.write(w);
   w.close();
   currentFile = fileName;
   changed = false;
   Save.setEnabled(false);
 }
 catch (IOException e)
 {
 }
}

代码示例来源:origin: us.ihmc/IHMCHumanoidBehaviors

private void saveFile(String fileName)
{
 try
 {
   FileWriter w = new FileWriter(fileName);
   area.write(w);
   w.close();
   currentFile = fileName;
   setTitle(currentFile);
   changed = false;
   Save.setEnabled(false);
 }
 catch (IOException e)
 {
 }
}

代码示例来源:origin: us.ihmc/ihmc-humanoid-behaviors

private void saveFile(String fileName)
{
 try
 {
   FileWriter w = new FileWriter(fileName);
   area.write(w);
   w.close();
   currentFile = fileName;
   setTitle(currentFile);
   changed = false;
   Save.setEnabled(false);
 }
 catch (IOException e)
 {
 }
}

代码示例来源:origin: stackoverflow.com

outFile = new BufferedWriter(new FileWriter(fileName));
n.write(outFile);   // *** here: ***

代码示例来源:origin: de.unkrig/antology

@Override public void
  run() {
    if (TextArea.this.property != null) {
      swingDialogTask.getProject().setProperty(TextArea.this.property, jTextArea.getText());
    }
    if (TextArea.this.file != null) {
      try {
        OutputStream os = new FileOutputStream(TextArea.this.file, TextArea.this.append);
        try {
          jTextArea.write(new OutputStreamWriter(os, TextArea.this.encoding));
          os.close();
        } finally {
          try { os.close(); } catch (Exception e) {}
        }
      } catch (IOException ioe) {
        throw ExceptionUtil.wrap(
          "Writing  file '" + TextArea.this.file + "'",
          ioe,
          BuildException.class
        );
      }
    }
  }
});

相关文章

JTextArea类方法