(Copyright requirements: This article is only authorized to use 9CBS, other personal and websites must not be reproduced, excerpt, if there is special demand to contact the author) 7) How to use?
A: Strictly speaking, the collection of CB is not a class, but a class template. It is used to achieve a collection of this abstract data type. Using it can define an actual set type, its general declaration mode is: typedef set
A: Of course, the following is some of its common operators and methods: CLEAR method: Clear all elements within the collection object, make the collection empty set; Contains method: Do not contain the specified element in the query collection, its statement: BOOL _FASTCALL Contains Const; Operator-: Two collections are governed, and the result set contains different elements in two collections; Operator *: See the intersection of two collections; Operator : ask two collections Convert; Operator <<: Add an element to the specified collection; Operator >>: Delete a specified element from the collection. In fact, the SET class should be relatively wide, such as determining if we press the left mouse button, you can use the following statement: if (Shift.contains (SSLEFT)). 9) I heard that there is a component that can be triggered in CB, can you tell us about its properties and events?
A: You are talking about the Timer component, which is located in the System Component page of the component column. It is not difficult to use it because his properties, the event is particularly small: Enabled Properties: Boolean type. The default is true, and the timer will trigger the ONTIMER event after a period of time. When this property is changed from False to True, the clock will restart the timing. Interval Property: This property is used to set a ONTIMER event once a long time, in milliseconds. The default is 1000 milliseconds. Ontimer Event: This event is triggered once when the enabled property is set to TRUE, and the time specified by the INTERVAL property is triggered once. 10) It turns out that the Timer component is so simple, but I don't know why it's a way to find a loop statement, can you give an example of an Ontimer event?