gacutil to manipulate the Global Assembly Cache can be found in
C:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\Bin
At first I tried to install the .NET SDK, but it was telling me that it was installed already. It is actually installed with Visual Studio. When you start the VisualStudio Command Prompt, the path to it is set already.
Tuesday, January 13, 2009
Sunday, November 30, 2008
Java logger
import java.util.logging.Logger;
import java.util.logging.FileHandler;
import java.util.logging.SimpleFormatter;
import java.util.logging.Level;
logger = Logger.getLogger("com.mycompany.conversion"); // logger internal name
FileHandler fileHandler = new FileHandler("basic.conversion.txt", 1000, 1);
fileHandler.setFormatter(new SimpleFormatter());
logger.addHandler(fileHandler);
logger.log(Level.INFO, " Initializing GgWebService");
See also:
C:\Program Files\Java\jdk1.6.0_10\jre\lib\logging.properties
.
import java.util.logging.FileHandler;
import java.util.logging.SimpleFormatter;
import java.util.logging.Level;
logger = Logger.getLogger("com.mycompany.conversion"); // logger internal name
FileHandler fileHandler = new FileHandler("basic.conversion.txt", 1000, 1);
fileHandler.setFormatter(new SimpleFormatter());
logger.addHandler(fileHandler);
logger.log(Level.INFO, " Initializing GgWebService");
See also:
C:\Program Files\Java\jdk1.6.0_10\jre\lib\logging.properties
.
Friday, November 21, 2008
Strings
string is an alias for String
String: UTF16
UTF16
wchar_t: UTF16 on Windows, UTF32 on Unix
wchar_t is not portable, better to use ICU instead.
typedef basic_string < char > string;
typedef basic_string < wchar_t > wstring;
wstring string1 = L"obecně";
UnicodeString: UTF16 internally. Note that the endianess of UTF-16 is platform dependent.
ICU does not use UCS-2. UCS-2 is a subset of UTF-16. UCS-2 does not support surrogates, and UTF-16 does support surrogates.
#ifdef UNICODE
typedef wchar_t TCHAR;
#else
typedef char TCHAR;
#endif
TCHAR * toto = _T("obecně");
Sunday, October 26, 2008
Sunday, October 12, 2008
Eclipse survival kit
create WAR files, or AAR axis2 archive files)
Windows > Preferences > Java > Code Style > Code Templates > Comments
Select Types
- tab spaces not taken into account (Helios, Ubuntu 64 bits)
- Needed to do a "apt-get update" after installing CDT otherwise, gave me funky compile error messages on printf and stuff
- To access the gdb CLI, select the gdb process node in the Debug view. The gdb command line will then be available in the Console view. Though no prompt is visible, you can enter commands at the bottom line of the Console view. Doing so may desynchronize the IDE and gdb, so be careful when driving the debugger using this interface.
- automatic save: Windows > Preferences > General > Workspace
create a sibbling directory of the sources root: search-l-2S-build
cd search-l-2S-build
cmake -G "Eclipse CDT4 - Unix Makefiles" -D CMAKE_BUILD_TYPE=Debug ../search-l-2S
In eclipse CDT:
File > Import Existing Projects into Workspace > Next
Select root directory => Répertoire "cmakebuild" créé plus haut
Source accessible in "Subprojects".
./eclipse_cdt -vmargs -XX:PermSize=512m -XX:MaxPermSize=512m -Xms1024m -Xmx1024m
You just get "Dynamic Web Project" creation menu only when you install J2EE Eclipse version
- eclipse.ini
if you get black zones within the Eclipse editor, you will have to switch from GTK3 to GTK2. To do this, add the following two lines to eclipse.ini
--launcher.GTK_version
2
when using the maven plugin, the "Java build path" in the Eclipse will take the default JRE Eclipse config unless you specify "maven-compiler-plugin" as artifact in the pom.xml with version 1.8 for example
window->Preferences, ensuite choisir Java->Code Style-> formatter et sélectionner "Java conventions [build-in]".
C# survival kit
* C# is the first “component oriented” language in the C/C++ family
* csharp string <--> C++ wchar_t
* to display a string from multiline (somewhat equivalent to the C++ backslash ):
string toto = @"toto
toto";
* One must specify “override” to the method in the subclass if one want to override a virtual method from the superclass (as opposed to C++ where override is automatic)
* Mutexes are of two types: local mutexes and named system mutexes. If you create a Mutex object using a constructor that accepts a name, it is associated with an operating-system object of that name. Named system mutexes are visible throughout the operating system, and can be used to synchronize the activities of processes.
* csharp string <--> C++ wchar_t
* to display a string from multiline (somewhat equivalent to the C++ backslash ):
string toto = @"toto
toto";
* One must specify “override” to the method in the subclass if one want to override a virtual method from the superclass (as opposed to C++ where override is automatic)
* Mutexes are of two types: local mutexes and named system mutexes. If you create a Mutex object using a constructor that accepts a name, it is associated with an operating-system object of that name. Named system mutexes are visible throughout the operating system, and can be used to synchronize the activities of processes.
Sunday, September 14, 2008
HTML frames automatic refresh
<script type="text/javascript">
top.frames['frame1'].location.reload();
top.frames['frame2'].location.reload();
</script>
<html>
<frameset rows="50%,50%">
<frame src="TestResults.html" name="frame2">
<frame src="Hem-1.0/nunit-logs/results-nunit_32.xml" name="frame1">
<frame src="Hem-1.0/nunit-logs/results-nunit_64.xml" name="frame1">
</frameset>
</html>
top.frames['frame1'].location.reload();
top.frames['frame2'].location.reload();
</script>
<html>
<frameset rows="50%,50%">
<frame src="TestResults.html" name="frame2">
<frame src="Hem-1.0/nunit-logs/results-nunit_32.xml" name="frame1">
<frame src="Hem-1.0/nunit-logs/results-nunit_64.xml" name="frame1">
</frameset>
</html>
Subscribe to:
Posts (Atom)