logo资料库

VISSIM的COM使用说明书.pdf

第1页 / 共239页
第2页 / 共239页
第3页 / 共239页
第4页 / 共239页
第5页 / 共239页
第6页 / 共239页
第7页 / 共239页
第8页 / 共239页
资料共239页,剩余部分请下载后查看
1 Introduction
1.1 Introductory Example
1.2 License and Registration
1.3 Instances
1.4 Conventions
2 Object Model
2.1 Model Overview
2.2 Vissim
2.3 Net
2.4 Simulation
2.5 DynamicAssignment
2.6 Graphics
2.7 Presentation
2.8 Evaluation
2.9 Links
2.10 Link
2.11 Nodes
2.12 Node
2.13 ParkingLots
2.14 ParkingLot
2.15 Paths
2.16 Path
2.17 DrivingBehaviorParSets
2.18 DrivingBehaviorParSet
2.19 TrafficCompositions
2.20 TrafficComposition
2.21 VehicleInputs
2.22 VehicleInput
2.23 Vehicles
2.24 Vehicle
2.25 RoutingDecisions
2.26 RoutingDecision
2.27 Routes
2.28 Route
2.29 DesiredSpeedDecisions
2.30 DesiredSpeedDecision
2.31 ReducedSpeedAreas
2.32 ReducedSpeedArea
2.33 StopSigns
2.34 StopSign
2.35 StaticObjects
2.36 StaticObject
2.37 SignalControllers
2.38 SignalController
2.39 Detectors
2.40 Detector
2.41 SignalGroups
2.42 SignalGroup
2.43 SignalHeads
2.44 SignalHead
2.45 PTCallingPoints
2.46 TransitLines
2.47 TransitLine
2.48 TransitStops
2.49 TransitStop
2.50 DataCollections
2.51 DataCollection
2.52 QueueCounters
2.53 QueueCounter
2.54 TravelTimes
2.55 TravelTime
2.56 Delays
2.57 Delay
2.58 LinkEvaluation
2.59 DataCollectionEvaluation
2.60 QueueCounterEvaluation
2.61 TravelTimeEvaluation
2.62 DelayEvaluation
2.63 NodeEvaluation
2.64 WorldPoint
3 COM Access Using Visual Basic
3.1 Creation of a Visual Basic Client
3.2 Collections (Different Ways to Enumerate)
3.3 Arrays
3.4 Error Handling
3.5 A Visual Basic Client Example
3.6 Advanced Issues Using Visual Basic
4 COM Access Using Visual C++
4.1 Creation of a VC++ Client
4.2 Collections (Different Ways to Enumerate)
4.3 Arrays
4.4 Error Handling
4.5 A Visual C++ Client Example
5 COM Access with .NET
5.1 Creation of a Client Using Visual Studio .NET
5.2 Arrays
5.3 Events
5.4 Error Handling
6 COM Access Using Java
6.1 Creation of a COM Wrapper
6.2 Creation of a Java client
7 COM Remote Access
8 Annexes
8.1 Error Messages
8.2 Warning Messages
8.3 Tips and Hints
8.4 Registry
VISSIM 4.30-00 COM Interface Manual PTV Planung Transport Verkehr AG
Copyright © PTV AG 2007 Planung Transport Verkehr AG Stumpfstraße 1 D-76131 Karlsruhe Germany All rights reserved. April 2007
Table of Contents 1 Introduction 1.1 1.2 1.3 1.4 Conventions Introductory Example License and Registration Instances 2 Object Model Vissim Simulation 2.1 Model Overview 2.2 2.3 Net 2.4 2.5 DynamicAssignment 2.6 Graphics 2.7 Presentation 2.8 Evaluation 2.9 Links 2.10 Link 2.11 Nodes 2.12 Node 2.13 ParkingLots 2.14 ParkingLot 2.15 Paths 2.16 Path 2.17 DrivingBehaviorParSets 2.18 DrivingBehaviorParSet 2.19 TrafficCompositions 2.20 TrafficComposition 2.21 VehicleInputs 2.22 VehicleInput 2.23 Vehicles 2.24 Vehicle 2.25 RoutingDecisions VISSIM 4.30-00 © PTV AG 2007 9 11 13 14 15 17 18 20 26 30 39 43 46 48 51 53 59 62 65 67 69 73 75 77 79 81 84 86 88 94 99 5
Table of Contents 2.26 RoutingDecision 2.27 Routes 2.28 Route 2.29 DesiredSpeedDecisions 2.30 DesiredSpeedDecision 2.31 ReducedSpeedAreas 2.32 ReducedSpeedArea 2.33 StopSigns 2.34 StopSign 2.35 StaticObjects 2.36 StaticObject 2.37 SignalControllers 2.38 SignalController 2.39 Detectors 2.40 Detector 2.41 SignalGroups 2.42 SignalGroup 2.43 SignalHeads 2.44 SignalHead 2.45 PTCallingPoints 2.46 TransitLines 2.47 TransitLine 2.48 TransitStops 2.49 TransitStop 2.50 DataCollections 2.51 DataCollection 2.52 QueueCounters 2.53 QueueCounter 2.54 TravelTimes 2.55 TravelTime 2.56 Delays 2.57 Delay 2.58 LinkEvaluation 2.59 DataCollectionEvaluation 2.60 QueueCounterEvaluation 2.61 TravelTimeEvaluation 102 106 109 112 114 117 119 122 124 127 130 132 134 137 139 142 144 147 149 151 153 155 158 160 162 165 169 171 174 176 179 181 184 187 189 191 6 VISSIM 4.30-00 © PTV AG 2007
2.62 DelayEvaluation 2.63 NodeEvaluation 2.64 WorldPoint 3 COM Access Using Visual Basic 3.1 Creation of a Visual Basic Client 3.2 Collections (Different Ways to Enumerate) 3.3 3.4 3.5 3.6 Arrays Error Handling A Visual Basic Client Example Advanced Issues Using Visual Basic 4 COM Access Using Visual C++ 4.1 Creation of a VC++ Client 4.2 Collections (Different Ways to Enumerate) 4.3 4.4 4.5 Arrays Error Handling A Visual C++ Client Example 5 COM Access with .NET 5.1 Creation of a Client Using Visual Studio .NET 5.2 5.3 5.4 Arrays Events Error Handling 6 COM Access Using Java 6.1 Creation of a COM Wrapper 6.2 Creation of a Java client 7 COM Remote Access 8 Annexes Error Messages 8.1 8.2 Warning Messages 8.3 8.4 Registry Tips and Hints Table of Contents 193 195 197 199 200 202 203 204 205 206 209 210 212 213 214 215 217 218 221 222 223 225 226 227 229 231 232 238 239 240 COM Interface Manual © PTV AG 2007 7
1 Introduction VISSIM can be applied as a powerful tool in analysis of a huge variety of transportation problems. Occasionally projects will require extensive pre- or post-processing or numerous scenarios to be investigated. For these cases VISSIM can be run from within other applications serving as a toolbox for transportation planning algorithms. Access to model data and simulations is provided through a COM interface, which allows VISSIM to work as an Automation Server and to export the objects, methods and properties described in this document. The VISSIM COM interface supports Microsoft Automation, so you can use any of the RAD (Rapid Application Development) tools ranging from scripting languages like Visual Basic Script or Java Script to programming environments like Visual C++ or Visual J++. The examples presented in this manual are mainly in Visual Basic, see page 199 for a little introduction. You will also find a short introduction on how to use it with Visual C++ on page 209. An introductory Visual Basic example will illustrate the flexibility of this approach. Assume that we want to run several simulations with different random seeds and get their respective link evaluations. You can use Excel and VBA (Visual Basic for Applications) to load the network, set the different random seeds and start the process. For example, if you want to use the network “fixed_time.inp” and to run four simulations with the random seeds 10, 20, 30 and 42 you can edit the following Excel sheet: random seed simulation file G:\PTV\DATA\FIXED_TIME.INP 10 20 30 42 You can also insert a button “START” (from the toolbox) to link with the Visual Basic code presented at the end of this section: To get the link evaluations by running the Excel macro you have to create a *.SAK file within the same directory beforehand. You may use the VISSIM Link Evaluation Dialog (or the LinkEvaluation interface) for this purpose: Start VISSIM 4.30-00 © PTV AG 2007 9
分享到:
收藏