Monday, March 26, 2012

Eclipse: Ant Build

Steps:
1) Expand the Java project
2) Choose build.xml
3) Right-click, choose Run As\Ant Build
4) Press F5 to refresh

Saturday, March 10, 2012

Eclipse: Speeding Up

Increase the amount of heap memory allocated to Eclipse to speed up execution when developing and debugging large applications.
To allocate 256MB, change the command line to launch Eclipse as follows:

C:\eclipse\eclipse.exe -vmargs -Xmx256M

Thursday, February 23, 2012

Eclipse: Access restriction: The type x is not accessible due to restriction on required library C:\Program Files\Java\jre6\lib\rt.jar

To resolve this problem go to project properties. Under Java Compiler>Errors/Warnings
Under "Deprecated and restricted API" change "Forbidden reference (access rules)" to "Ignore"


Thursday, February 16, 2012

C#: Copying 2 buffers


Use Buffer.BlockCopy method
<span style="color:Blue;">public</span> <span style="color:Blue;">static</span> <span style="color:Blue;">void</span> BlockCopy(
Array src,
<span style="color:Blue;">int</span> srcOffset,
Array dst,
<span style="color:Blue;">int</span> dstOffset,
<span style="color:Blue;">int</span> count
)
Example:
byte[] dataRcvd = new byte[20];
byte[] commBuffer = new byte[5];
Buffer.BlockCopy(commBuffer,0, this.dataRcvd,0, 5);

Wednesday, February 15, 2012

Viewing CVS Repositories

Step 1:From the CVS menu, choose Remote>Checkout module...


Step 2:The Checkout settings dialog will pop-up. From the Checkout settings tab, click the "..." button to display the list of repositories.


Step 3: Choose the repository you want to checkout then click OK


Step 4:Click OK again.


Step 5: After a successful checkout, you should see the project folder in your workspace.