?? tickerclient.py
字號:
# $Id: tickerclient.py,v 1.4 2002/02/01 15:07:36 marijn Exp $# An air traffic simulation game.# Copyright (C) 2000,1,2 Marijn Vriens <marijn@sanity.dhs.org>## This program is free software; you can redistribute it and/or modify# it under the terms of the GNU General Public License as published by# the Free Software Foundation; either version 2 of the License, or# (at your option) any later version.## This program is distributed in the hope that it will be useful,# but WITHOUT ANY WARRANTY; without even the implied warranty of# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the# GNU General Public License for more details.## You should have received a copy of the GNU General Public License# along with this program; if not, write to the Free Software# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USAimport setup import osos.environ["IDLPATH"] = setup.idl_dirimport CORBA, SimulationServer, SimulationServer__POAimport timeclass TickerClient: """ Simple class that does a update() request every once in a while to the server.""" def __init__(self, opts): print "TicketClient ctor" for x in opts: if x[0] == '--ior': ior = x[1] break orb = CORBA.ORB_init() self._handle = orb.string_to_object(ior) def run(self): while(1): time.sleep(setup.sim_ticker_delay) self._handle.update()# $Log: tickerclient.py,v $# Revision 1.4 2002/02/01 15:07:36 marijn# updated copyright information## Revision 1.3 2001/12/25 02:00:09 marijn# various fixes and updates.## Revision 1.2 2001/11/19 00:25:58 marijn# py merged back into HEAD## Revision 1.1.2.4 2001/11/16 03:48:38 marijn# Removed debuging message## Revision 1.1.2.3 2001/11/15 05:20:30 marijn# Ticker process now started automaticly by sim-server## Revision 1.1.2.2 2001/11/14 06:27:47 marijn# Simserver now pings the meta server.## Revision 1.1.2.1 2001/11/11 07:25:16 marijn# Added simserver update ticker#
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -