我正在寻找一段时间,但没有找到.如何在NetBeans 7.0.1中创建文档?
我的文件看起来像:
/** Class Description of MyClass */
public class ScanReader{
}
Run Code Online (Sandbox Code Playgroud)
在我的项目属性中,我使用复选框选中了所有选项,而Javadoc选项中没有任何选项(我尝试使用全局路径-d但没有任何反应).当我进行构建或构建和清理时,我没有看到任何关于文档的内容,也没有任何新的项目文件.
我想定义一个我可以AppController在默认布局中使用的数组.
我怎么能在CakePHP中做到这一点?
我正在从内存中读取内容(在字节数组中),然后我想转换它,但结果类似于"wanteddata\0\0\0\0\0\0\0\0 ...".我怎样才能把它剪成"wantdata"?我不确定wantdata的大小,所以我给了最大尺寸:14.我从内存和转换中读取的方式:
String w="";
ReadProcessMemory(phandle, bAddr, buffer, 14, out bytesRW);
w = ASCIIEncoding.ASCII.GetString(buffer);
Run Code Online (Sandbox Code Playgroud) 我想在 PictureBox 中绘制一些小图片(连续 4 x 32px 图像),所以我应该覆盖 OnPaint 方法还是需要制作扩展 PictureBox 的新组件?我试过这个,它在 Java 中工作,但不是在这里:
this.pictureBox1 = new System.Windows.Forms.PictureBox()
{
protected override void OnPaint(PaintEventArgs e)
{
// If there is an image and it has a location,
// paint it when the Form is repainted.
Graphics g = e.Graphics;
// Draw a string on the PictureBox.
g.DrawString("Test, is that working?",
new Font("Arial", 10), System.Drawing.Brushes.Blue, new Point(30, 30));
}
}
Run Code Online (Sandbox Code Playgroud)
InitializeComponent 方法的完整代码:
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Tools));
this.pictureBox1 = …Run Code Online (Sandbox Code Playgroud) 我想制作服务器应用程序.在开始时,它应该创建用于组织每个连接的线程并在Listbox中写入日志.我有问题因为我不知道在哪里可以创建可以访问Form1.Listbox1的新线程.这是我试过的:
public class ServerLoop
{
Form1 form1;
public ServerLoop(Form1 f)
{
form1 = f;
}
public void loop()
{
form1.addConsoleMessage("test");
}
}
Run Code Online (Sandbox Code Playgroud)
和Form1类:
public partial class Form1 : Form
{
public Thread tServerLoop;
public ServerLoop serverLoop;
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
console.Items.Clear();
players.Items.Clear();
players.Items.Add("Witaj w serwerze");
addConsoleMessage("test");
serverLoop = new ServerLoop(this);
tServerLoop = new Thread(serverLoop.loop);
tServerLoop.Start();
}
private void connectButton_Click(object sender, EventArgs e)
{
}
public void addConsoleMessage(String msg)
{
console.Items.Add(msg);
}
} …Run Code Online (Sandbox Code Playgroud) 那些是数组约束:数组有自定义大小,我将在程序顶部读取,这将是指向我自己的类Tree的指针数组,数组需要每个单元格的恒定读取时间.
这是我的代码不起作用:
scanf("%d %d",&n,&q);
Tree *pointers = new Tree[n];
pointers[0]->value = NULL;