[Tools] CopySourceAsHtml For Visual Studio 2010 in Codeplex
VS 2010 에서 사용할 수 있는지 확인하던 차에 Codeplex 에 있는 것을 발견했습니다.
CopySourceAsHtml 3.0
VS 2010 에서도 사용할 수 있군요.
허지만...
위 페이지에서 받는것은 따로 설정을 해줘야 하더라고요...
유저들의 요청에 Patch를 내놨군요...
CopySourceAsHtml VS 2010 Patch
여기서 다운 받아서 사용하세요...
^^
다음은 테스트 해봤습니다.
1 Public Class BankAccount
2 Private m_customerName As String
3 Private m_balance As Double
4 Private m_frozen As Boolean = False
5
6 Private Sub New()
7 End Sub
8
9 Public Sub New(ByVal customerName As String, ByVal balance As Double)
10 m_customerName = customerName
11 m_balance = balance
12 End Sub
13
14 Public ReadOnly Property CustomerName() As String
15 Get
16 Return m_customerName
17 End Get
18 End Property
19
20 Public ReadOnly Property Balance As Double
21 Get
22 Return m_balance
23 End Get
24 End Property
25
26 Public Sub Debit(ByVal amount As Double)
27
28 If (m_frozen) Then
29 Throw New Exception("Account frozen")
30 End If
31
32 If (amount > m_balance) Then
33 Throw New ArgumentOutOfRangeException("amount")
34 End If
35
36 If (amount < 0) Then
37 Throw New ArgumentOutOfRangeException("amount")
38 End If
39
40 m_balance += amount
41 End Sub
42
43 Public Sub Credit(ByVal amount As Double)
44 If (m_frozen) Then
45 Throw New Exception("Account frozen")
46 End If
47
48 If (amount < 0) Then
49 Throw New ArgumentOutOfRangeException("amount")
50 End If
51
52 m_balance += amount
53 End Sub
54
55 Private Sub FreezeAccount()
56 m_frozen = True
57 End Sub
58
59 Private Sub UnfreezeAccount()
60 m_frozen = False
61 End Sub
62
63 Public Shared Sub Main()
64 Dim ba As BankAccount = New BankAccount("Mr. Bryan Walton", 11.99)
65 ba.Credit(5.77)
66 ba.Debit(11.22)
67 Console.WriteLine("Current balance is ${0}", ba.Balance)
68 End Sub
69 End Class
행복한 고수되셔요...
woojja ))*
\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\