HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion

ProgramFilesDir -> 값 바꾸기
Posted by zennken

Svchost.exe

OS/Windows 2008. 10. 6. 21:40
Svchost.exe : a generic host process name for services that run from dynamic-link libraries (DLLs).

* To view the list of services in svchost
Command: Tasklist /svc

* To see more information about each process
Tasklist /FI "PID eq processID" (with the quotation marks)

From: http://support.microsoft.com/?kbid=314056
Posted by zennken

Java Enum Class

Development/Java 2008. 10. 6. 10:04
Since Java SE 5.0

Enum -> String: Enum에서 이름 가져오기
EnumType.Instance.name()

String -> Enum: 이름을 이용해 해당 Enum 찾기
EnumType e = (EnumType) Enum.valueOf(EnumType.class, "Name")

Instance sequence number: Instance의 순서
EnumType.Instance.ordinal()

모든 instance 가져오기
for (EnumType variable: EnumType.values())
{
...
}

switch
switch (EnumVariable)
{
case Instance: {stmt}
...
}


제목이 말하듯 Java의 enumeration은 Enum class의 child class이다.








Posted by zennken

zennken

달력