⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 entities.cls

📁 u8
💻 CLS
字号:
VERSION 1.0 CLASS
BEGIN
  MultiUse = -1  'True
  Persistable = 0  'NotPersistable
  DataBindingBehavior = 0  'vbNone
  DataSourceBehavior  = 0  'vbNone
  MTSTransactionMode  = 0  'NotAnMTSObject
END
Attribute VB_Name = "Entities"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = True
Attribute VB_PredeclaredId = False
Attribute VB_Exposed = True
'--------------------------------
'时间:2001.11.12
'版权:北京用友软件股份有限公司
'设计:章景峰
'编码:章景峰
'说明:U8资金管理---实体对象
'--------------------------------
Option Explicit

Private m_Col           As Collection
Private m_EOMetaData    As EntityObject

Public Function Append(EO As EntityObject, Optional Key As String) As EntityObject
    If Not IsNull(Key) And Key <> "" Then
        m_Col.Add EO, Key
    Else
        m_Col.Add EO ', eo.OID
    End If
    
    Set Append = EO
End Function

'参数vIndexKey,表示集合中元素的索引或关键字
Public Property Get Item(vIndexKey As Variant) As EntityObject
Attribute Item.VB_UserMemId = 0
    Set Item = m_Col(vIndexKey)
End Property

'集合中元素的数目
Public Property Get Count() As Long
    Count = m_Col.Count
End Property

'删除集合中的元素时使用。
Public Sub Delete(vIndexKey As Variant)
    m_Col.Remove vIndexKey
End Sub

Public Property Get NewEnum() As IUnknown
Attribute NewEnum.VB_UserMemId = -4
    '本属性允许用 For...Each 语法枚举该集合。
    Set NewEnum = m_Col.[_NewEnum]
End Property

Private Sub Class_Initialize()
    '创建类后创建集合
    Set m_Col = New Collection
End Sub

Private Sub Class_Terminate()
    '类终止后破坏集合
    Set m_Col = Nothing
End Sub

Public Property Get EOMetaData() As EntityObject
    Set EOMetaData = m_EOMetaData
End Property

Public Property Set EOMetaData(ByVal vData As EntityObject)
    Set m_EOMetaData = vData
End Property

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -