W
wildman
Looking at an asp.net website with a lot of OOP and I am trying to
understand where the benefit of all this might be.
There is a user control with codebehind properties that looks like
this:
Partial Class uc
Inherits System.Web.UI.UserControl
Implements UM.IUIBuildingBlock
Public Property Checked() As Boolean Implements
XX.IUIBuildingBlock.Checked
Get
Return Nothing
End Get
Set(ByVal Value As Boolean)
End Set
End Property
.
==
IUIBuildingBlock.vb looks like this:
Namespace XX
Public Interface IUIBuildingBlock
ReadOnly Property DataType() As XXDataTypes
Property Checked() As Boolean
End Interface
End Namespace
===
XXDataTypes.vb looks like this:
Namespace XX
Public Enum XXDataTypes
[String]
[Integer]
[Double]
[Date]
[DateTime]
[Currency]
[Boolean]
[DropDownList]
[CheckBox]
[RadioButton]
End Enum
End Namespace
Why do you suppose the developer might have gone through all of this?
Rather than just coding like this?
Public Property Checked() As Boolean
Get
Return Nothing
End Get
Set(ByVal Value As Boolean)
End Set
End Property
Thanks for any help or information! Can you explain in lea mans terms
with a simple example of why we would benefit from all this extra
code? Also keeping in mind that my example does not show all the DAL/
BAL code where we create a collection class and object class for every
single table in another probject that was referenced in.
understand where the benefit of all this might be.
There is a user control with codebehind properties that looks like
this:
Partial Class uc
Inherits System.Web.UI.UserControl
Implements UM.IUIBuildingBlock
Public Property Checked() As Boolean Implements
XX.IUIBuildingBlock.Checked
Get
Return Nothing
End Get
Set(ByVal Value As Boolean)
End Set
End Property
.
==
IUIBuildingBlock.vb looks like this:
Namespace XX
Public Interface IUIBuildingBlock
ReadOnly Property DataType() As XXDataTypes
Property Checked() As Boolean
End Interface
End Namespace
===
XXDataTypes.vb looks like this:
Namespace XX
Public Enum XXDataTypes
[String]
[Integer]
[Double]
[Date]
[DateTime]
[Currency]
[Boolean]
[DropDownList]
[CheckBox]
[RadioButton]
End Enum
End Namespace
Why do you suppose the developer might have gone through all of this?
Rather than just coding like this?
Public Property Checked() As Boolean
Get
Return Nothing
End Get
Set(ByVal Value As Boolean)
End Set
End Property
Thanks for any help or information! Can you explain in lea mans terms
with a simple example of why we would benefit from all this extra
code? Also keeping in mind that my example does not show all the DAL/
BAL code where we create a collection class and object class for every
single table in another probject that was referenced in.