VTK
vtkSocketCollection.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkSocketCollection.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
23 #ifndef vtkSocketCollection_h
24 #define vtkSocketCollection_h
25 
26 #include "vtkCommonSystemModule.h" // For export macro
27 #include "vtkCollection.h"
28 
29 class vtkSocket;
31 {
32 public:
35  void PrintSelf(ostream& os, vtkIndent indent);
36 
37  // Add Socket to the collection.
38  void AddItem(vtkSocket* soc);
39 
44  int SelectSockets(unsigned long msec =0);
45 
47 
50  {return this->SelectedSocket; }
52 
54 
55  void ReplaceItem(int i, vtkObject *);
56  void RemoveItem(int i);
59 protected:
63 
65 private:
66  // Hide the standard AddItem.
67  void AddItem(vtkObject* o) { this->Superclass::AddItem(o); }
68 
69 private:
70  vtkSocketCollection(const vtkSocketCollection&); // Not implemented.
71  void operator=(const vtkSocketCollection&); // Not implemented.
72 };
73 
74 #endif
75 
vtkCollection.h
VTKCOMMONSYSTEM_EXPORT
#define VTKCOMMONSYSTEM_EXPORT
Definition: vtkCommonSystemModule.h:15
vtkTypeMacro
#define vtkTypeMacro(thisClass, superclass)
Definition: vtkSetGet.h:642
vtkObject
abstract base class for most VTK objects
Definition: vtkObject.h:62
vtkSocketCollection
a collection for sockets.
Definition: vtkSocketCollection.h:31
vtkSocketCollection::SelectedSocket
vtkSocket * SelectedSocket
Definition: vtkSocketCollection.h:64
vtkSocketCollection::RemoveItem
void RemoveItem(vtkObject *)
vtkSocketCollection::GetLastSelectedSocket
vtkSocket * GetLastSelectedSocket()
Definition: vtkSocketCollection.h:49
vtkCollection
create and manipulate unsorted lists of objects
Definition: vtkCollection.h:53
vtkCommonSystemModule.h
vtkSocketCollection::vtkSocketCollection
vtkSocketCollection()
vtkSocketCollection::ReplaceItem
void ReplaceItem(int i, vtkObject *)
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkSocketCollection::SelectSockets
int SelectSockets(unsigned long msec=0)
vtkSocketCollection::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent)
vtkSocketCollection::New
static vtkSocketCollection * New()
vtkSocket
BSD socket encapsulation.
Definition: vtkSocket.h:30
vtkSocketCollection::RemoveItem
void RemoveItem(int i)
vtkCollection::AddItem
void AddItem(vtkObject *)
vtkSocketCollection::RemoveAllItems
void RemoveAllItems()
vtkSocketCollection::~vtkSocketCollection
~vtkSocketCollection()
vtkSocketCollection::AddItem
void AddItem(vtkSocket *soc)