From 5770cbb3c6543a39a79876cd59c4736803c4d988 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:21 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/BufferedSocket.cxx | 165 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 165 insertions(+) create mode 100644 Ivy/BufferedSocket.cxx (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx new file mode 100644 index 0000000..33818a0 --- /dev/null +++ b/Ivy/BufferedSocket.cxx @@ -0,0 +1,165 @@ +// BufferedSocket.cpp: implementation of the CBufferedSocket class. +// +////////////////////////////////////////////////////////////////////// + +#include "stdafx.h" +#include "BufferedSocket.h" + +#ifdef _DEBUG +#undef THIS_FILE +static char THIS_FILE[]=__FILE__; +#define new DEBUG_NEW +#endif + +//IMPLEMENT_DYNAMIC(CBufferedSocket, CThreadedSocket) + +////////////////////////////////////////////////////////////////////// +// Construction/Destruction +////////////////////////////////////////////////////////////////////// + +CBufferedSocket::CBufferedSocket() +{ + separator = '\n'; + ptr = buf; + connected = false; + InitializeCriticalSection( &m_CritSection ); +} + +CBufferedSocket::~CBufferedSocket() +{ + +} +void CBufferedSocket::Accept(CBufferedSocket& rConnectedSocket, SOCKADDR* lpSockAddr , int* lpSockAddrLen ) +{ + CThreadedSocket::Accept(rConnectedSocket, lpSockAddr , lpSockAddrLen ); + rConnectedSocket.connected = true; +} +void CBufferedSocket::OnReceive(int nErrorCode) +{ + + + char *ptr_nl; + long nb_to_read = 0; + long nb; + + SOCKADDR addr; + int len; + + /* limitation taille buffer */ + nb_to_read = MAX_BUFFER - ( ptr - buf ); + if( nb_to_read == 0 ) + { + TRACE("Erreur message trop long sans LF\n"); + ptr = buf; + return; + } + nb = ReceiveFrom( ptr, nb_to_read, &addr, &len, MSG_PARTIAL ); + if ( nb == SOCKET_ERROR ) + { + int err = GetLastError(); + if ( err != WSAESHUTDOWN ) // shutdown by remote side ? + TRACE("error Receive %d socket %d\n",GetLastError(),m_hSocket); + Close(); + return; + } + if ( nb == 0 ) // shutdown by remote side ? + { + Close(); + return; + } + + ptr += nb; + assert ( ptr < (buf +sizeof( buf ))); + *ptr = '\0'; + ptr = buf; + while( (ptr_nl = strchr( ptr, '\n' ))) + { + *ptr_nl = '\0'; + //TRACE("message %s\n", ptr ); + OnReceive( ptr ); + ptr = ++ptr_nl; + } + if ( *ptr != '\0' ) + { /* recopie ligne incomplete au debut du buffer */ + strcpy( buf, ptr ); + ptr = buf + strlen(buf); + } + else + { + ptr = buf; + } + + +} + +void CBufferedSocket::OnReceive( char *line ) +{ +} +void CBufferedSocket::SetSeparator( char sep ) +{ + separator = sep; +} +void CBufferedSocket::OnWakeup() +{ + string msg; + BOOL empty; + try + { + // on essaye de garder la section critique a l'interieur de la boucle + // pour permettre l'entrelacement avec la partie emetrice + do + { + EnterCriticalSection( &m_CritSection ); + empty = buf_out.empty(); + if ( !empty ) msg = buf_out.front(); + LeaveCriticalSection( &m_CritSection ); + //TRACE("CBufferedSocket::OnWakeup Sending buffer %s\n",msg.c_str()); + if ( !empty ) + { + int lg = msg.length(); + CThreadedSocket::Send( msg.c_str(), lg ); + EnterCriticalSection( &m_CritSection ); + buf_out.pop_front(); + LeaveCriticalSection( &m_CritSection ); + } + } while ( !empty ); + } + catch ( CThreadedSocketException* e ) + { + int err = e->GetError(); + if ( err == WSAEWOULDBLOCK ) + { + // put back the buffer, preserving the order + //EnterCriticalSection( &m_CritSection ); + //buf_out.push_front( msg); + //LeaveCriticalSection( &m_CritSection ); + } + else TRACE("CBufferedSocket::OnWakeup error %d Sending buffer %s \n",err,msg.c_str()); + } + + +} +void CBufferedSocket::OnSend( int nErrorCode ) +{ + OnWakeup(); +} +void CBufferedSocket::OnConnect( int nErrorCode ) +{ + connected = true; + OnWakeup(); +//TRACE("CBufferedSocket::OnConnect buffer empty %d\n",buf_out.IsEmpty()); +} +void CBufferedSocket::Send ( const char * data ) +{ + //BOOL toBeSignaled; + EnterCriticalSection( &m_CritSection ); + //toBeSignaled = buf_out.IsEmpty() && connected; + buf_out.push_back( string(data) ); + LeaveCriticalSection( &m_CritSection ); + //TRACE("CBufferedSocket::Send Adding buffer to send count %d\n",buf_out.size()); + if ( connected ) + { + BOOL ok = WSASetEvent( m_hEvent[1] ); + if ( !ok ) TRACE( "CBufferedSocket::Send Error SetEvent %d\n", WSAGetLastError()); + } +} -- cgit v1.1 From de0e97b1d6104588a4fe4720d5906507ebd37ada Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:23 +0000 Subject: Utilisateur : Fcolin Date : 14/11/00 Heure : 18:58 Archivé dans $/Ivy (vss 2) --- Ivy/BufferedSocket.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 33818a0..39c7203 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -43,7 +43,7 @@ void CBufferedSocket::OnReceive(int nErrorCode) long nb; SOCKADDR addr; - int len; + int len = sizeof( addr ); /* limitation taille buffer */ nb_to_read = MAX_BUFFER - ( ptr - buf ); -- cgit v1.1 From 30797436d86f3cd922fca6f53536c6805e8d321d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:24 +0000 Subject: Utilisateur : Fcolin Date : 23/01/01 Heure : 13:12 Archivé dans $/Ivy Commentaire: remove 'using name space std;' (vss 3) --- Ivy/BufferedSocket.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 39c7203..d19b68f 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -101,7 +101,7 @@ void CBufferedSocket::SetSeparator( char sep ) } void CBufferedSocket::OnWakeup() { - string msg; + String msg; BOOL empty; try { @@ -154,7 +154,7 @@ void CBufferedSocket::Send ( const char * data ) //BOOL toBeSignaled; EnterCriticalSection( &m_CritSection ); //toBeSignaled = buf_out.IsEmpty() && connected; - buf_out.push_back( string(data) ); + buf_out.push_back( String(data) ); LeaveCriticalSection( &m_CritSection ); //TRACE("CBufferedSocket::Send Adding buffer to send count %d\n",buf_out.size()); if ( connected ) -- cgit v1.1 From c5851089facb6bcc36b736d21efd9941941667c3 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:26 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 4) --- Ivy/BufferedSocket.cxx | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index d19b68f..63fd6c0 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -69,7 +69,7 @@ void CBufferedSocket::OnReceive(int nErrorCode) } ptr += nb; - assert ( ptr < (buf +sizeof( buf ))); + ASSERT( ptr < (buf +sizeof( buf ))); *ptr = '\0'; ptr = buf; while( (ptr_nl = strchr( ptr, '\n' ))) @@ -101,8 +101,8 @@ void CBufferedSocket::SetSeparator( char sep ) } void CBufferedSocket::OnWakeup() { - String msg; - BOOL empty; + string msg; + bool empty; try { // on essaye de garder la section critique a l'interieur de la boucle @@ -134,7 +134,7 @@ void CBufferedSocket::OnWakeup() //buf_out.push_front( msg); //LeaveCriticalSection( &m_CritSection ); } - else TRACE("CBufferedSocket::OnWakeup error %d Sending buffer %s \n",err,msg.c_str()); + else TRACE("CBufferedSocket::OnWakeup error %d Sending buffer %s \n",err,msg); } @@ -154,12 +154,12 @@ void CBufferedSocket::Send ( const char * data ) //BOOL toBeSignaled; EnterCriticalSection( &m_CritSection ); //toBeSignaled = buf_out.IsEmpty() && connected; - buf_out.push_back( String(data) ); + buf_out.push_back( string(data) ); LeaveCriticalSection( &m_CritSection ); //TRACE("CBufferedSocket::Send Adding buffer to send count %d\n",buf_out.size()); if ( connected ) { - BOOL ok = WSASetEvent( m_hEvent[1] ); - if ( !ok ) TRACE( "CBufferedSocket::Send Error SetEvent %d\n", WSAGetLastError()); +// BOOL ok = WSASetEvent( m_hEvent[1] ); +// if ( !ok ) TRACE( "CBufferedSocket::Send Error SetEvent %d\n", WSAGetLastError()); } } -- cgit v1.1 From 17b10f43897aec90cf5e4b57ebc7ab0e26ca5b83 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:28 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 5) --- Ivy/BufferedSocket.cxx | 79 ++++++++++++++++++++++---------------------------- 1 file changed, 35 insertions(+), 44 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 63fd6c0..6a17b71 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -6,13 +6,10 @@ #include "BufferedSocket.h" #ifdef _DEBUG -#undef THIS_FILE -static char THIS_FILE[]=__FILE__; +#define DEBUG_NEW new(__FILE__, __LINE__) #define new DEBUG_NEW #endif -//IMPLEMENT_DYNAMIC(CBufferedSocket, CThreadedSocket) - ////////////////////////////////////////////////////////////////////// // Construction/Destruction ////////////////////////////////////////////////////////////////////// @@ -99,54 +96,48 @@ void CBufferedSocket::SetSeparator( char sep ) { separator = sep; } -void CBufferedSocket::OnWakeup() +void CBufferedSocket::OnSend( int nErrorCode ) { string msg; bool empty; - try - { - // on essaye de garder la section critique a l'interieur de la boucle - // pour permettre l'entrelacement avec la partie emetrice - do + + // on essaye de garder la section critique a l'interieur de la boucle + // pour permettre l'entrelacement avec la partie emetrice + do + { + EnterCriticalSection( &m_CritSection ); + empty = buf_out.empty(); + if ( !empty ) msg = buf_out.front(); + LeaveCriticalSection( &m_CritSection ); + TRACE("CBufferedSocket::OnSend Sending buffer %s\n",msg.c_str()); + if ( !empty ) { - EnterCriticalSection( &m_CritSection ); - empty = buf_out.empty(); - if ( !empty ) msg = buf_out.front(); - LeaveCriticalSection( &m_CritSection ); - //TRACE("CBufferedSocket::OnWakeup Sending buffer %s\n",msg.c_str()); - if ( !empty ) - { - int lg = msg.length(); - CThreadedSocket::Send( msg.c_str(), lg ); + int lg = msg.length(); + int sent = CThreadedSocket::Send( msg.c_str(), lg ); + if ( sent == lg ) + { // emission correcte on enleve le msg de la file EnterCriticalSection( &m_CritSection ); buf_out.pop_front(); LeaveCriticalSection( &m_CritSection ); } - } while ( !empty ); - } - catch ( CThreadedSocketException* e ) - { - int err = e->GetError(); - if ( err == WSAEWOULDBLOCK ) - { - // put back the buffer, preserving the order - //EnterCriticalSection( &m_CritSection ); - //buf_out.push_front( msg); - //LeaveCriticalSection( &m_CritSection ); + else + { // erreur + int err = GetLastError(); + if ( err == WSAEWOULDBLOCK ) // si la file est pleine on sort en silence ! + { + } + else + TRACE("CBufferedSocket::OnWakeup error %d Sending buffer %s \n",err,msg); + break; } - else TRACE("CBufferedSocket::OnWakeup error %d Sending buffer %s \n",err,msg); - } - - -} -void CBufferedSocket::OnSend( int nErrorCode ) -{ - OnWakeup(); + } + } while ( !empty ); } + void CBufferedSocket::OnConnect( int nErrorCode ) { connected = true; - OnWakeup(); + StartWriter(); //TRACE("CBufferedSocket::OnConnect buffer empty %d\n",buf_out.IsEmpty()); } void CBufferedSocket::Send ( const char * data ) @@ -157,9 +148,9 @@ void CBufferedSocket::Send ( const char * data ) buf_out.push_back( string(data) ); LeaveCriticalSection( &m_CritSection ); //TRACE("CBufferedSocket::Send Adding buffer to send count %d\n",buf_out.size()); - if ( connected ) - { -// BOOL ok = WSASetEvent( m_hEvent[1] ); -// if ( !ok ) TRACE( "CBufferedSocket::Send Error SetEvent %d\n", WSAGetLastError()); - } +// if ( connected ) +// { + bool ok = SignalWriter(); + if ( !ok ) TRACE( "CBufferedSocket::SignalWriter Error %d\n", ::GetLastError()); +// } } -- cgit v1.1 From f5edd45381d5f08f77defbb975e1c8b5df3a18e4 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:31 +0000 Subject: Utilisateur : Fcolin Date : 19/02/01 Heure : 10:37 Archivé dans $/Ivy (vss 6) --- Ivy/BufferedSocket.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 6a17b71..b065a15 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -109,9 +109,10 @@ void CBufferedSocket::OnSend( int nErrorCode ) empty = buf_out.empty(); if ( !empty ) msg = buf_out.front(); LeaveCriticalSection( &m_CritSection ); - TRACE("CBufferedSocket::OnSend Sending buffer %s\n",msg.c_str()); if ( !empty ) { +// TRACE("CBufferedSocket::OnSend Sending buffer %s\n",msg.c_str()); + int lg = msg.length(); int sent = CThreadedSocket::Send( msg.c_str(), lg ); if ( sent == lg ) -- cgit v1.1 From 4c3311ee071d9f58bef1dff82a2772778f251cf1 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:33 +0000 Subject: Utilisateur : Fcolin Date : 19/02/01 Heure : 17:00 Archivé dans $/Ivy (vss 7) --- Ivy/BufferedSocket.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index b065a15..3d3474a 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -50,7 +50,7 @@ void CBufferedSocket::OnReceive(int nErrorCode) ptr = buf; return; } - nb = ReceiveFrom( ptr, nb_to_read, &addr, &len, MSG_PARTIAL ); + nb = ReceiveFrom( ptr, nb_to_read, &addr, &len, 0/*MSG_PARTIAL*/ ); if ( nb == SOCKET_ERROR ) { int err = GetLastError(); -- cgit v1.1 From 2a2c244787f3f9584c49b93d499e1d6f1af114c6 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:34 +0000 Subject: Utilisateur : Fcolin Date : 23/05/01 Heure : 10:25 Archivé dans $/Ivy (vss 8) --- Ivy/BufferedSocket.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 3d3474a..441d580 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -53,9 +53,9 @@ void CBufferedSocket::OnReceive(int nErrorCode) nb = ReceiveFrom( ptr, nb_to_read, &addr, &len, 0/*MSG_PARTIAL*/ ); if ( nb == SOCKET_ERROR ) { - int err = GetLastError(); + int err = this->GetLastError(); if ( err != WSAESHUTDOWN ) // shutdown by remote side ? - TRACE("error Receive %d socket %d\n",GetLastError(),m_hSocket); + TRACE("error Receive %d socket %d\n",this->GetLastError(),m_hSocket); Close(); return; } @@ -123,7 +123,7 @@ void CBufferedSocket::OnSend( int nErrorCode ) } else { // erreur - int err = GetLastError(); + int err = this->GetLastError(); if ( err == WSAEWOULDBLOCK ) // si la file est pleine on sort en silence ! { } @@ -152,6 +152,6 @@ void CBufferedSocket::Send ( const char * data ) // if ( connected ) // { bool ok = SignalWriter(); - if ( !ok ) TRACE( "CBufferedSocket::SignalWriter Error %d\n", ::GetLastError()); + if ( !ok ) TRACE( "CBufferedSocket::SignalWriter Error %d\n", this->GetLastError()); // } } -- cgit v1.1 From e661571a5a49870ebd4df32520c18ffb69e96b50 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:36 +0000 Subject: Utilisateur : Fcolin Date : 17/07/01 Heure : 18:25 Archivé dans $/Ivy (vss 9) --- Ivy/BufferedSocket.cxx | 4 ---- 1 file changed, 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 441d580..2e15cab 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -5,10 +5,6 @@ #include "stdafx.h" #include "BufferedSocket.h" -#ifdef _DEBUG -#define DEBUG_NEW new(__FILE__, __LINE__) -#define new DEBUG_NEW -#endif ////////////////////////////////////////////////////////////////////// // Construction/Destruction -- cgit v1.1 From ff8b9139c740027bbbec018b76a00d5c0ff3ebc5 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:38 +0000 Subject: Utilisateur : Fcolin Date : 20/09/01 Heure : 9:40 Archivé dans $/Ivy (vss 10) --- Ivy/BufferedSocket.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 2e15cab..491098e 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -135,7 +135,7 @@ void CBufferedSocket::OnConnect( int nErrorCode ) { connected = true; StartWriter(); -//TRACE("CBufferedSocket::OnConnect buffer empty %d\n",buf_out.IsEmpty()); + TRACE("CBufferedSocket::OnConnect buffer size %d\n",buf_out.size()); } void CBufferedSocket::Send ( const char * data ) { -- cgit v1.1 From fb5f1f4e3561eba211e9cafc5ea290f2adb88200 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:40 +0000 Subject: Utilisateur : Fcolin Date : 4/02/03 Heure : 8:59 Archivé dans $/Bus/Ivy Commentaire: (vss 11) --- Ivy/BufferedSocket.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 491098e..0265e3b 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -135,7 +135,7 @@ void CBufferedSocket::OnConnect( int nErrorCode ) { connected = true; StartWriter(); - TRACE("CBufferedSocket::OnConnect buffer size %d\n",buf_out.size()); +// TRACE("CBufferedSocket::OnConnect buffer size %d\n",buf_out.size()); } void CBufferedSocket::Send ( const char * data ) { -- cgit v1.1 From 22aa1c6735a22db795f7f10679d285beda36d9be Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:42 +0000 Subject: Utilisateur : Fcolin Date : 9/02/04 Heure : 15:25 Archivé dans $/Bus/Ivy Commentaire: (vss 12) --- Ivy/BufferedSocket.cxx | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 0265e3b..03a2704 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -120,11 +120,15 @@ void CBufferedSocket::OnSend( int nErrorCode ) else { // erreur int err = this->GetLastError(); - if ( err == WSAEWOULDBLOCK ) // si la file est pleine on sort en silence ! - { - } - else - TRACE("CBufferedSocket::OnWakeup error %d Sending buffer %s \n",err,msg); + switch ( err ){ + case WSAEWOULDBLOCK: // si la file est pleine on sort en silence ! + break; + case WSAECONNABORTED: // broken pipe on sort en silence + break; + default: + TRACE("CBufferedSocket::OnWakeup error %d Sending buffer %s \n",err,msg.c_str()); + break; + } break; } } -- cgit v1.1 From 00546c6eb0c54919615c1e28858403fcd232c06a Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:44 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:45 Archivé dans $/Bus/Ivy Commentaire: (vss 13) --- Ivy/BufferedSocket.cxx | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 03a2704..864da25 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -2,7 +2,7 @@ // ////////////////////////////////////////////////////////////////////// -#include "stdafx.h" +#include "IvyStdAfx.h" #include "BufferedSocket.h" @@ -60,27 +60,27 @@ void CBufferedSocket::OnReceive(int nErrorCode) Close(); return; } - - ptr += nb; - ASSERT( ptr < (buf +sizeof( buf ))); - *ptr = '\0'; - ptr = buf; - while( (ptr_nl = strchr( ptr, '\n' ))) - { - *ptr_nl = '\0'; - //TRACE("message %s\n", ptr ); - OnReceive( ptr ); - ptr = ++ptr_nl; - } + + ptr += nb; + ASSERT( ptr < (buf +sizeof( buf ))); + *ptr = '\0'; + ptr = buf; + while( (ptr_nl = strchr( ptr, '\n' ))) + { + *ptr_nl = '\0'; + //TRACE("message %s\n", ptr ); + OnReceive( ptr ); + ptr = ++ptr_nl; + } if ( *ptr != '\0' ) - { /* recopie ligne incomplete au debut du buffer */ - strcpy( buf, ptr ); - ptr = buf + strlen(buf); - } - else - { - ptr = buf; - } + { /* recopie ligne incomplete au debut du buffer */ + strcpy( buf, ptr ); + ptr = buf + strlen(buf); + } + else + { + ptr = buf; + } } -- cgit v1.1 From 863c7be9778c1dab03380ba7d72e015448ab9206 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:46 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 18:23 Archivé dans $/Bus/Ivy Commentaire: (vss 14) --- Ivy/BufferedSocket.cxx | 50 +++++++++++++++++++++++++++++--------------------- 1 file changed, 29 insertions(+), 21 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 864da25..5f6c994 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -5,6 +5,7 @@ #include "IvyStdAfx.h" #include "BufferedSocket.h" +#define BUFFER_SIZE 4096 ////////////////////////////////////////////////////////////////////// // Construction/Destruction @@ -13,7 +14,9 @@ CBufferedSocket::CBufferedSocket() { separator = '\n'; - ptr = buf; + buffer_size = BUFFER_SIZE; + buffer = (char*)malloc( buffer_size ); + current_ptr = buffer; connected = false; InitializeCriticalSection( &m_CritSection ); } @@ -29,9 +32,8 @@ void CBufferedSocket::Accept(CBufferedSocket& rConnectedSocket, SOCKADDR* lpSock } void CBufferedSocket::OnReceive(int nErrorCode) { - - - char *ptr_nl; + char *ptr_sep; + char *ptr; long nb_to_read = 0; long nb; @@ -39,14 +41,20 @@ void CBufferedSocket::OnReceive(int nErrorCode) int len = sizeof( addr ); /* limitation taille buffer */ - nb_to_read = MAX_BUFFER - ( ptr - buf ); + nb_to_read = buffer_size - (current_ptr - buffer ); if( nb_to_read == 0 ) { - TRACE("Erreur message trop long sans LF\n"); - ptr = buf; - return; + buffer_size *= 2; /* twice old size */ + buffer = (char*)realloc( buffer, buffer_size ); + if (!buffer ) + { + TRACE("HandleSocket Buffer Memory Alloc Error\n"); + exit(0); + } + TRACE( "Buffer Limit reached realloc new size %ld\n", buffer_size ); + nb_to_read = buffer_size - (current_ptr - buffer ); } - nb = ReceiveFrom( ptr, nb_to_read, &addr, &len, 0/*MSG_PARTIAL*/ ); + nb = ReceiveFrom( current_ptr, nb_to_read, &addr, &len, 0/*MSG_PARTIAL*/ ); if ( nb == SOCKET_ERROR ) { int err = this->GetLastError(); @@ -61,26 +69,26 @@ void CBufferedSocket::OnReceive(int nErrorCode) return; } - ptr += nb; - ASSERT( ptr < (buf +sizeof( buf ))); - *ptr = '\0'; - ptr = buf; - while( (ptr_nl = strchr( ptr, '\n' ))) + current_ptr += nb; + ASSERT( current_ptr < (buffer + buffer_size) ); + ptr = buffer; + while ((ptr_sep = (char*)memchr (ptr, separator, current_ptr - ptr ))) { - *ptr_nl = '\0'; + *ptr_sep = '\0'; //TRACE("message %s\n", ptr ); OnReceive( ptr ); - ptr = ++ptr_nl; + ptr = ++ptr_sep; } - if ( *ptr != '\0' ) + if (ptr < current_ptr ) { /* recopie ligne incomplete au debut du buffer */ - strcpy( buf, ptr ); - ptr = buf + strlen(buf); + len = current_ptr - ptr; + memcpy (buffer, ptr, len ); + current_ptr = buffer + len; } else { - ptr = buf; - } + current_ptr = buffer; + } } -- cgit v1.1 From 6df79c23c311d014c426ab00d3bc3c9a8204b429 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:48 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 15) --- Ivy/BufferedSocket.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 5f6c994..cae2404 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -70,7 +70,7 @@ void CBufferedSocket::OnReceive(int nErrorCode) } current_ptr += nb; - ASSERT( current_ptr < (buffer + buffer_size) ); + //ASSERT( current_ptr < (buffer + buffer_size) ); ptr = buffer; while ((ptr_sep = (char*)memchr (ptr, separator, current_ptr - ptr ))) { @@ -102,7 +102,7 @@ void CBufferedSocket::SetSeparator( char sep ) } void CBufferedSocket::OnSend( int nErrorCode ) { - string msg; + ivy::string msg; bool empty; // on essaye de garder la section critique a l'interieur de la boucle @@ -154,7 +154,7 @@ void CBufferedSocket::Send ( const char * data ) //BOOL toBeSignaled; EnterCriticalSection( &m_CritSection ); //toBeSignaled = buf_out.IsEmpty() && connected; - buf_out.push_back( string(data) ); + buf_out.push_back( ivy::string(data) ); LeaveCriticalSection( &m_CritSection ); //TRACE("CBufferedSocket::Send Adding buffer to send count %d\n",buf_out.size()); // if ( connected ) -- cgit v1.1 From 9b22935b0b601fa0ebce1ced5d8eb2c7499eb2a0 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:50 +0000 Subject: Utilisateur : Fcolin Date : 23/09/05 Heure : 15:27 Archivé dans $/Bus/Ivy Commentaire: (vss 16) --- Ivy/BufferedSocket.cxx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index cae2404..11eecf5 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -34,11 +34,11 @@ void CBufferedSocket::OnReceive(int nErrorCode) { char *ptr_sep; char *ptr; - long nb_to_read = 0; - long nb; + size_t nb_to_read = 0; + size_t nb; SOCKADDR addr; - int len = sizeof( addr ); + size_t len = sizeof( addr ); /* limitation taille buffer */ nb_to_read = buffer_size - (current_ptr - buffer ); @@ -117,8 +117,8 @@ void CBufferedSocket::OnSend( int nErrorCode ) { // TRACE("CBufferedSocket::OnSend Sending buffer %s\n",msg.c_str()); - int lg = msg.length(); - int sent = CThreadedSocket::Send( msg.c_str(), lg ); + size_t lg = msg.length(); + size_t sent = CThreadedSocket::Send( msg.c_str(), lg ); if ( sent == lg ) { // emission correcte on enleve le msg de la file EnterCriticalSection( &m_CritSection ); -- cgit v1.1 From eb8866478a0f97eaa7b9e52259043672da332778 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:52 +0000 Subject: Utilisateur : Fcolin Date : 17/11/05 Heure : 15:08 Archivé dans $/Bus/Ivy Commentaire: nice Bug in nextArg not reentrant routine due to static variable (vss 17) --- Ivy/BufferedSocket.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 11eecf5..7df2bce 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -55,6 +55,7 @@ void CBufferedSocket::OnReceive(int nErrorCode) nb_to_read = buffer_size - (current_ptr - buffer ); } nb = ReceiveFrom( current_ptr, nb_to_read, &addr, &len, 0/*MSG_PARTIAL*/ ); + ASSERT ( memchr( current_ptr, 0, nb) == NULL ); if ( nb == SOCKET_ERROR ) { int err = this->GetLastError(); @@ -70,7 +71,6 @@ void CBufferedSocket::OnReceive(int nErrorCode) } current_ptr += nb; - //ASSERT( current_ptr < (buffer + buffer_size) ); ptr = buffer; while ((ptr_sep = (char*)memchr (ptr, separator, current_ptr - ptr ))) { @@ -78,6 +78,7 @@ void CBufferedSocket::OnReceive(int nErrorCode) //TRACE("message %s\n", ptr ); OnReceive( ptr ); ptr = ++ptr_sep; + //ASSERT( ptr < (buffer + buffer_size) ); } if (ptr < current_ptr ) { /* recopie ligne incomplete au debut du buffer */ -- cgit v1.1 From 38c6ccda650d81aca69dafa3d033bfeb8160e94c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:54 +0000 Subject: Utilisateur : Fcolin Date : 18/11/05 Heure : 11:46 Archivé dans $/Bus/Ivy Commentaire: repassage a la STL et correction bug multithread (vss 18) --- Ivy/BufferedSocket.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 7df2bce..3335e09 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -23,7 +23,7 @@ CBufferedSocket::CBufferedSocket() CBufferedSocket::~CBufferedSocket() { - + free( buffer ); } void CBufferedSocket::Accept(CBufferedSocket& rConnectedSocket, SOCKADDR* lpSockAddr , int* lpSockAddrLen ) { -- cgit v1.1 From 98630f19f487c261bd68defc285c8216c0f7718c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:56 +0000 Subject: Utilisateur : Fcolin Date : 19/04/06 Heure : 15:07 Archivé dans $/Bus/Ivy Commentaire: (vss 19) --- Ivy/BufferedSocket.cxx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.cxx b/Ivy/BufferedSocket.cxx index 3335e09..1a11c56 100644 --- a/Ivy/BufferedSocket.cxx +++ b/Ivy/BufferedSocket.cxx @@ -36,6 +36,7 @@ void CBufferedSocket::OnReceive(int nErrorCode) char *ptr; size_t nb_to_read = 0; size_t nb; + char *tmp_buf; SOCKADDR addr; size_t len = sizeof( addr ); @@ -45,12 +46,13 @@ void CBufferedSocket::OnReceive(int nErrorCode) if( nb_to_read == 0 ) { buffer_size *= 2; /* twice old size */ - buffer = (char*)realloc( buffer, buffer_size ); - if (!buffer ) + tmp_buf = (char*)realloc( buffer, buffer_size ); + if (!tmp_buf ) { TRACE("HandleSocket Buffer Memory Alloc Error\n"); exit(0); } + buffer = tmp_buf; TRACE( "Buffer Limit reached realloc new size %ld\n", buffer_size ); nb_to_read = buffer_size - (current_ptr - buffer ); } -- cgit v1.1 From c3cdcd52eb86f5ed96a515370e073e604ebb1a53 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:53:58 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/BufferedSocket.h | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 Ivy/BufferedSocket.h (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.h b/Ivy/BufferedSocket.h new file mode 100644 index 0000000..5f104c6 --- /dev/null +++ b/Ivy/BufferedSocket.h @@ -0,0 +1,42 @@ +// BufferedSocket.h: interface for the CBufferedSocket class. +// +////////////////////////////////////////////////////////////////////// + +#if !defined(AFX_BUFFEREDSOCKET_H__ECAC808B_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_) +#define AFX_BUFFEREDSOCKET_H__ECAC808B_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_ + +#if _MSC_VER > 1000 +#pragma once +#endif // _MSC_VER > 1000 + +#include "ThreadedSocket.h" + +class CBufferedSocket : public CThreadedSocket +{ +// DECLARE_DYNAMIC(CBufferedSocket) +public: + CBufferedSocket(); + virtual ~CBufferedSocket(); + void OnReceive( int nErrorCode ); + void OnSend( int nErrorCode ); + void OnConnect(int nErrorCode); + void OnWakeup(); + virtual void OnReceive( char *line ); + virtual void Accept(CBufferedSocket& rConnectedSocket, + SOCKADDR* lpSockAddr = NULL, int* lpSockAddrLen = NULL); + void SetSeparator( char sep ); + void Send ( const char * data ); +protected: + bool connected; /* wait to be connected before sending any Data */ + char separator; + /* buffer de reception de l'application */ +#define MAX_BUFFER 2048 + // MAX_BUFFER +1 pour ajouter \0 a la fin + char buf[MAX_BUFFER+1]; + char *ptr; + // Buffer Emission + CRITICAL_SECTION m_CritSection; + list buf_out; +}; + +#endif // !defined(AFX_BUFFEREDSOCKET_H__ECAC808B_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_) -- cgit v1.1 From b2d1035cde733bc2e70f5976fa8453808bcca416 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:00 +0000 Subject: Utilisateur : Fcolin Date : 23/01/01 Heure : 13:12 Archivé dans $/Ivy Commentaire: remove 'using name space std;' (vss 2) --- Ivy/BufferedSocket.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.h b/Ivy/BufferedSocket.h index 5f104c6..e72138f 100644 --- a/Ivy/BufferedSocket.h +++ b/Ivy/BufferedSocket.h @@ -36,7 +36,7 @@ protected: char *ptr; // Buffer Emission CRITICAL_SECTION m_CritSection; - list buf_out; + std::list buf_out; }; #endif // !defined(AFX_BUFFEREDSOCKET_H__ECAC808B_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_) -- cgit v1.1 From 558c5dd8030af085ba6caf392a4f5bf4bc8b41a8 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:02 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 3) --- Ivy/BufferedSocket.h | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.h b/Ivy/BufferedSocket.h index e72138f..1e0d118 100644 --- a/Ivy/BufferedSocket.h +++ b/Ivy/BufferedSocket.h @@ -2,12 +2,9 @@ // ////////////////////////////////////////////////////////////////////// -#if !defined(AFX_BUFFEREDSOCKET_H__ECAC808B_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_) -#define AFX_BUFFEREDSOCKET_H__ECAC808B_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_ -#if _MSC_VER > 1000 #pragma once -#endif // _MSC_VER > 1000 + #include "ThreadedSocket.h" @@ -36,7 +33,6 @@ protected: char *ptr; // Buffer Emission CRITICAL_SECTION m_CritSection; - std::list buf_out; + list buf_out; }; -#endif // !defined(AFX_BUFFEREDSOCKET_H__ECAC808B_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_) -- cgit v1.1 From 6701078aaeb12a8a3bab96b5301a4f3778806adf Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:04 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 4) --- Ivy/BufferedSocket.h | 1 - 1 file changed, 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.h b/Ivy/BufferedSocket.h index 1e0d118..bd146ec 100644 --- a/Ivy/BufferedSocket.h +++ b/Ivy/BufferedSocket.h @@ -17,7 +17,6 @@ public: void OnReceive( int nErrorCode ); void OnSend( int nErrorCode ); void OnConnect(int nErrorCode); - void OnWakeup(); virtual void OnReceive( char *line ); virtual void Accept(CBufferedSocket& rConnectedSocket, SOCKADDR* lpSockAddr = NULL, int* lpSockAddrLen = NULL); -- cgit v1.1 From d3a7a9e4bc5b2a15d0825b41a740535cd6759fa7 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:06 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 18:23 Archivé dans $/Bus/Ivy Commentaire: (vss 5) --- Ivy/BufferedSocket.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.h b/Ivy/BufferedSocket.h index bd146ec..70e0b5e 100644 --- a/Ivy/BufferedSocket.h +++ b/Ivy/BufferedSocket.h @@ -26,10 +26,9 @@ protected: bool connected; /* wait to be connected before sending any Data */ char separator; /* buffer de reception de l'application */ -#define MAX_BUFFER 2048 - // MAX_BUFFER +1 pour ajouter \0 a la fin - char buf[MAX_BUFFER+1]; - char *ptr; + long buffer_size; + char *buffer; + char *current_ptr; // Buffer Emission CRITICAL_SECTION m_CritSection; list buf_out; -- cgit v1.1 From 89717ecba42128b4d3ec0afaf601540cd647530c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:08 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 6) --- Ivy/BufferedSocket.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.h b/Ivy/BufferedSocket.h index 70e0b5e..3920e64 100644 --- a/Ivy/BufferedSocket.h +++ b/Ivy/BufferedSocket.h @@ -31,6 +31,6 @@ protected: char *current_ptr; // Buffer Emission CRITICAL_SECTION m_CritSection; - list buf_out; + ivy::list buf_out; }; -- cgit v1.1 From 00aba9041cbb3de4c38531d56750c8c25a975c28 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:10 +0000 Subject: Utilisateur : Fcolin Date : 17/11/05 Heure : 15:08 Archivé dans $/Bus/Ivy Commentaire: nice Bug in nextArg not reentrant routine due to static variable (vss 7) --- Ivy/BufferedSocket.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/BufferedSocket.h b/Ivy/BufferedSocket.h index 3920e64..851ead1 100644 --- a/Ivy/BufferedSocket.h +++ b/Ivy/BufferedSocket.h @@ -24,7 +24,7 @@ public: void Send ( const char * data ); protected: bool connected; /* wait to be connected before sending any Data */ - char separator; + int separator; /* buffer de reception de l'application */ long buffer_size; char *buffer; -- cgit v1.1 From 87abbc06c1146ff80457407150c4e212b4ed4916 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:12 +0000 Subject: Utilisateur : Fcolin Date : 30/01/01 Heure : 17:33 Créé (vss 1) --- Ivy/DataTypes.h | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 Ivy/DataTypes.h (limited to 'Ivy') diff --git a/Ivy/DataTypes.h b/Ivy/DataTypes.h new file mode 100644 index 0000000..e69de29 -- cgit v1.1 From dc8fec9b2b2d00be9751afde91a14d2a841039f4 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:14 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 2) --- Ivy/DataTypes.h | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) (limited to 'Ivy') diff --git a/Ivy/DataTypes.h b/Ivy/DataTypes.h index e69de29..53bef2b 100644 --- a/Ivy/DataTypes.h +++ b/Ivy/DataTypes.h @@ -0,0 +1,81 @@ +#pragma once + +#ifdef WIN32 +#ifdef IVY_EXPORTS +class _declspec(dllexport) string; +#else +#pragma comment(lib,"Ivy.LIB" ) +class _declspec(dllimport) string; +#endif +#endif + +class string { +public: + string(); + string( const char * s); + int length(); + bool empty(); + void erase(int start=0, int len = -1); + void append( const char *s , int len ); + void insert(int index, const char * s); + string substr( int start, int len = -1 ); + int find_first_of( const char* s ); + int rfind( char c ); + operator +=(string s); + string operator +(string s); + // Nondestructive typecast operator + operator const char*() const; + const char *c_str() const; // remove this ugly thing +}; + +template class Iterator { +public: + T & operator !=(Iterator i); + T & operator ++(); + operator const T*() const; + T & second; + +}; + + +template class list { +public: + void clear(); + bool empty(); + T front(); + pop_front(); + void push_back( T data ); + typedef Iterator iterator; + iterator begin(); + iterator end(); + void remove( T data ); +}; + +template class vector { +public: + void clear(); + int size(); + // Nondestructive typecast operator + operator const T*() const; + // Accesses indexed component of vector + T & operator [](int i); + // Accesses indexed component of vector + const T & operator [](int i) const; + void push_back( T data ); + void remove( T data ); + +}; + +template class map { +public: + void clear(); + int size(); + bool empty(); + find(I i ); + typedef Iterator iterator; + iterator begin(); + iterator end(); + void erase( I i ); + // Accesses indexed component of vector + const T & operator [](I i) const; +}; \ No newline at end of file -- cgit v1.1 From 5ee431e3130e11fd8450222ec95402cca01594fa Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:16 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 3) --- Ivy/DataTypes.h | 321 ++++++++++++++++++++++++++++++++++++++++++++++---------- 1 file changed, 268 insertions(+), 53 deletions(-) (limited to 'Ivy') diff --git a/Ivy/DataTypes.h b/Ivy/DataTypes.h index 53bef2b..85be4d6 100644 --- a/Ivy/DataTypes.h +++ b/Ivy/DataTypes.h @@ -11,71 +11,286 @@ class _declspec(dllimport) string; class string { public: - string(); - string( const char * s); - int length(); - bool empty(); - void erase(int start=0, int len = -1); - void append( const char *s , int len ); - void insert(int index, const char * s); - string substr( int start, int len = -1 ); - int find_first_of( const char* s ); - int rfind( char c ); - operator +=(string s); - string operator +(string s); + string(size_t len = 0) + { ptr = allocBuffer( len ); }; + string ( const string& s ) + { ptr = 0; copy( s.ptr, s.size ); } + string( const char * s, int len = -1 ) + { + ptr = 0; + if ( len < 0 ) + len = strlen(s) ; + copy( s, len ); + } + + ~string() + { delete ptr; } + size_t length() + { return size; } + bool empty() const + { return size==0; } + void copy( const char * s, int len ) + { + char *newptr = allocBuffer( len ); + strncpy( newptr, s, len ); + if ( ptr ) delete [] ptr; + ptr = newptr; + } + void erase(int start=0, int len = -1) + { + char *newptr; + size_t real_len; + real_len = len < 0 ? size - start : len; + if ( real_len > size ) real_len = size; + newptr = allocBuffer( size - real_len ); + strncpy( newptr, ptr , start ); + strncpy( &newptr[start], &ptr[start+real_len], size - start ); + delete ptr; + ptr = newptr; + } + void append( const char *s , int len = -1 ) + { + insert ( size, s , len ); + } + void insert(int index, const char * s, int len = -1) + { + char *newptr; + if ( len < 0 ) len = strlen(s) ; + newptr = allocBuffer( size + len ); + strncpy( newptr , ptr, index ); + strncpy( newptr+index , s, len ) ; + strncpy( newptr+index+len , &ptr[index], len ) ; + delete ptr; + ptr = newptr; + } + string substr( int start, int len = -1 ) + { return string ( &ptr[start], len ); } + int find_first_of( const char* strCharSet ) + { char *fnd = strpbrk( ptr, strCharSet ); if ( fnd ) return fnd - ptr; else return -1; } + int rfind( char c ) + { char *fnd = strrchr( ptr, c); if ( fnd ) return fnd - ptr; else return -1; } +// friend string operator + (const string& left, const char* right); +// friend string operator + (const char* left, const string& right); + friend string operator + (const string& left, const string& right) + { + string str( left.size + right.size ); + str.append( left.ptr, left.size); + str.append( right.ptr, right.size); + return str; + } + operator +=(string s) + { + append( s.ptr, s.size ); + } + operator +=(char c) + { append( &c, 1);} + string operator +(string s) const + { string str ( ptr, size ); str.append( s.ptr, s.size ); return str; } + string operator +(const char c) const + { string str ( ptr, size ); str.append( &c, 1); return str; } + string& operator=(const string& s) + { copy(s.ptr,s.size); return *this; } + string& operator=(const char* s) + { copy(s,strlen(s)); return *this; } // Nondestructive typecast operator - operator const char*() const; - const char *c_str() const; // remove this ugly thing + operator const char*() const + { return ptr; } + const char *c_str() const // remove this ugly thing + { return ptr; } +private: + char *ptr; + size_t size; + // always allocate one extra character for '\0' termination + char *allocBuffer(int len) + { + char *newptr; + size = len; + newptr = new char[len+1] ; + newptr[len] = '\0'; + return newptr; + } + }; -template class Iterator { -public: - T & operator !=(Iterator i); - T & operator ++(); - operator const T*() const; - T & second; -}; template class list { + +protected: + struct _Node; + friend struct _Node; + typedef struct _Node Node; + typedef Node* NodePtr; + struct _Node { + NodePtr next, prev; + T value; + }; + public: - void clear(); - bool empty(); - T front(); - pop_front(); - void push_back( T data ); - typedef Iterator iterator; - iterator begin(); - iterator end(); - void remove( T data ); + + friend class iterator; + class iterator { + public: + iterator() + {ptr = 0;} + iterator(NodePtr p) + {ptr = p;} + T& operator*() const + {return ptr->value; } + T* operator->() const + {return &(ptr->value); } + iterator& operator++() + {ptr = ptr->next; + return (*this); } + iterator operator++(int) + {iterator tmp = *this; + ++*this; + return (tmp); } + iterator& operator--() + {ptr = ptr.prev;); + return (*this); } + iterator operator--(int) + {iterator tmp = *this; + --*this; + return (tmp); } + bool operator==(const iterator& p) const + {return (ptr == p.ptr); } + bool operator!=(const iterator& p) const + {return (ptr != p.ptr); } + NodePtr next() const + {return ptr->next; }; + NodePtr prev() const + {return ptr->prev ; }; + NodePtr node() const + {return (ptr); } + protected: + NodePtr ptr; + }; + + list() + { head = 0; } + bool empty() + { return head == 0 ; } + T& front() + {return head->value; } + iterator erase(iterator n) + { + NodePtr p = n.prev(); + NodePtr s = (n++).node(); + delete p->next; + p->next = s; + s->prev = p; + return n; + } + void pop_front() + { + NodePtr newhead = head->next; + newhead->prev = head->prev; + head->prev->next = newhead; + delete head; + head = (head == newhead) ? 0 : newhead; + } + iterator erase(iterator first, iterator last) + { + while (first != last) + erase(first++); + return (first); + } + void clear() + {erase(begin(), end()); } + void push_back( T value ) + { + NodePtr p = new Node; + p->value = value; + if ( head ) + { + p->next = head; + p->prev = head->prev; + head->prev->next = p; + head->prev = p; + } + else { + head = p; + p->next = p->prev = p; + } + } + void remove( const T& data ) + { + iterator last = end(); + for (iterator iter = begin(); iter != last; ) + if (*iter == data) + erase(iter++); + else + ++iter; + } + iterator begin() + {return (iterator(head)); } + iterator end() + { + if (head ) + return (iterator(head->prev)); + else return (iterator(head)); + } + protected: + NodePtr head; + }; template class vector { public: - void clear(); - int size(); - // Nondestructive typecast operator - operator const T*() const; - // Accesses indexed component of vector - T & operator [](int i); + + vector ( ) + { data = 0; len = 0; } + size_t size() + { return len; } + void reserve( size_t index ) + { + if ( index >= len ) + { + size_t i; + T* newdata = new T[index+1]; + for ( i = 0; i < len ; i ++ ) + newdata[i] = data[i]; + for ( i = len; i < index+1 ; i ++ ) + newdata[i] = 0; + if ( data ) delete [] data; + data = newdata; + len = index+1; + } + } // Accesses indexed component of vector - const T & operator [](int i) const; - void push_back( T data ); - void remove( T data ); - + T & operator [](size_t index ) + { + // reserve( index ); // TODO or NOT check range + return data[index] ; + } + T & operator [](size_t index ) const + { + return data[index] ; + } + void push_back( const T& value ) + { + T* newdata = new T[len+1]; + for ( unsigned int i = 0; i < len ; i ++ ) + newdata[i] = data[i]; + newdata[len++] = value; + if ( data ) delete [] data; + data = newdata; + } + void erase( int i ) + { + data[i] = 0; + } + void clear() + { + delete [] data; + data = 0; + len = 0; + } + +private: + T* data; + size_t len; }; -template class map { -public: - void clear(); - int size(); - bool empty(); - find(I i ); - typedef Iterator iterator; - iterator begin(); - iterator end(); - void erase( I i ); - // Accesses indexed component of vector - const T & operator [](I i) const; -}; \ No newline at end of file -- cgit v1.1 From 6faa30da0755977ed7dab2e6190519221f39915b Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:18 +0000 Subject: Utilisateur : Fcolin Date : 14/02/01 Heure : 18:47 Archivé dans $/Ivy (vss 4) --- Ivy/DataTypes.h | 117 +++++++++++++++++++++++++++++++------------------------- 1 file changed, 65 insertions(+), 52 deletions(-) (limited to 'Ivy') diff --git a/Ivy/DataTypes.h b/Ivy/DataTypes.h index 85be4d6..99b6e05 100644 --- a/Ivy/DataTypes.h +++ b/Ivy/DataTypes.h @@ -2,13 +2,15 @@ #ifdef WIN32 #ifdef IVY_EXPORTS -class _declspec(dllexport) string; +//class _declspec(dllexport) string; #else -#pragma comment(lib,"Ivy.LIB" ) -class _declspec(dllimport) string; +//#pragma comment(lib,"Ivy.LIB" ) +//class _declspec(dllimport) string; #endif #endif +#include + class string { public: string(size_t len = 0) @@ -24,17 +26,16 @@ public: } ~string() - { delete ptr; } + { delete [] ptr; } size_t length() { return size; } bool empty() const { return size==0; } void copy( const char * s, int len ) { - char *newptr = allocBuffer( len ); - strncpy( newptr, s, len ); if ( ptr ) delete [] ptr; - ptr = newptr; + ptr = allocBuffer( len ); + strncpy( ptr, s, len ); } void erase(int start=0, int len = -1) { @@ -59,7 +60,7 @@ public: newptr = allocBuffer( size + len ); strncpy( newptr , ptr, index ); strncpy( newptr+index , s, len ) ; - strncpy( newptr+index+len , &ptr[index], len ) ; + strncpy( newptr+index+len , &ptr[index], size - (index+len) ) ; delete ptr; ptr = newptr; } @@ -82,6 +83,10 @@ public: { append( s.ptr, s.size ); } + operator +=(const char* s) + { + append( s, strlen(s) ); + } operator +=(char c) { append( &c, 1);} string operator +(string s) const @@ -138,8 +143,10 @@ public: {ptr = p;} T& operator*() const {return ptr->value; } - T* operator->() const - {return &(ptr->value); } +// T* operator->() const +// {return &(ptr->value); } +// T* operator->() const +// {return (&**this); } iterator& operator++() {ptr = ptr->next; return (*this); } @@ -148,7 +155,7 @@ public: ++*this; return (tmp); } iterator& operator--() - {ptr = ptr.prev;); + {ptr = ptr.prev; return (*this); } iterator operator--(int) {iterator tmp = *this; @@ -169,28 +176,53 @@ public: }; list() - { head = 0; } + { + head = new Node; + head->next = head->prev = head; + } + ~list() + { + clear(); + delete head; + } bool empty() - { return head == 0 ; } + { return head->next == head ; } T& front() - {return head->value; } - iterator erase(iterator n) + {return (*begin()); } + const T& front() const + {return (*begin()); } + T& back() + {return (*(--end())); } + const T& back() const + {return (*(--end())); } + iterator erase(iterator p) { - NodePtr p = n.prev(); - NodePtr s = (n++).node(); - delete p->next; - p->next = s; - s->prev = p; - return n; + NodePtr s = (p++).node(); + s->prev->next = s->next; + s->next->prev = s->prev; + delete s; + return (p); } - void pop_front() + + iterator insert(iterator p, const T& v =T()) { - NodePtr newhead = head->next; - newhead->prev = head->prev; - head->prev->next = newhead; - delete head; - head = (head == newhead) ? 0 : newhead; + NodePtr s = p.node(); + NodePtr newnode = new Node; + newnode->value = v; + newnode->prev = s->prev; + newnode->next = s; + s->prev->next = newnode; + s->prev = newnode; + return (iterator(newnode)); } + void push_front(const T& v) + {insert(begin(), v); } + void pop_front() + {erase(begin()); } + void push_back(const T& v) + {insert(end(), v); } + void pop_back() + {erase(--end()); } iterator erase(iterator first, iterator last) { while (first != last) @@ -199,22 +231,7 @@ public: } void clear() {erase(begin(), end()); } - void push_back( T value ) - { - NodePtr p = new Node; - p->value = value; - if ( head ) - { - p->next = head; - p->prev = head->prev; - head->prev->next = p; - head->prev = p; - } - else { - head = p; - p->next = p->prev = p; - } - } + void remove( const T& data ) { iterator last = end(); @@ -225,13 +242,9 @@ public: ++iter; } iterator begin() - {return (iterator(head)); } + {return (iterator(head->next)); } iterator end() - { - if (head ) - return (iterator(head->prev)); - else return (iterator(head)); - } + {return (iterator(head));} protected: NodePtr head; @@ -249,14 +262,14 @@ public: if ( index >= len ) { size_t i; - T* newdata = new T[index+1]; + T* newdata = new T[index]; for ( i = 0; i < len ; i ++ ) newdata[i] = data[i]; - for ( i = len; i < index+1 ; i ++ ) + for ( i = len; i < index ; i ++ ) newdata[i] = 0; if ( data ) delete [] data; data = newdata; - len = index+1; + len = index; } } // Accesses indexed component of vector -- cgit v1.1 From 4ab2c9cd41abe5f904272cb2f5260fa6caed2138 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:20 +0000 Subject: Utilisateur : Fcolin Date : 27/06/01 Heure : 14:24 Archivé dans $/Ivy (vss 5) --- Ivy/DataTypes.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/DataTypes.h b/Ivy/DataTypes.h index 99b6e05..acc4aa0 100644 --- a/Ivy/DataTypes.h +++ b/Ivy/DataTypes.h @@ -260,6 +260,9 @@ public: void reserve( size_t index ) { if ( index >= len ) + resize( index ); + } + void resize( size_t index ) { size_t i; T* newdata = new T[index]; @@ -271,7 +274,6 @@ public: data = newdata; len = index; } - } // Accesses indexed component of vector T & operator [](size_t index ) { -- cgit v1.1 From fe66807c8cefa06f12c6af5798d2ed3e14aa953c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:22 +0000 Subject: Utilisateur : Fcolin Date : 5/11/02 Heure : 9:57 Archivé dans $/Bus/Ivy Commentaire: (vss 6) --- Ivy/DataTypes.h | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'Ivy') diff --git a/Ivy/DataTypes.h b/Ivy/DataTypes.h index acc4aa0..2267de7 100644 --- a/Ivy/DataTypes.h +++ b/Ivy/DataTypes.h @@ -79,16 +79,18 @@ public: str.append( right.ptr, right.size); return str; } - operator +=(string s) + const string& operator +=(string s) { - append( s.ptr, s.size ); + return append( s.ptr, s.size ); } - operator +=(const char* s) + const string& operator +=(const char* s) { - append( s, strlen(s) ); + return append( s, strlen(s) ); + } + const string& operator +=(char c) + { + return append( &c, 1); } - operator +=(char c) - { append( &c, 1);} string operator +(string s) const { string str ( ptr, size ); str.append( s.ptr, s.size ); return str; } string operator +(const char c) const -- cgit v1.1 From 52382fb13d0312f26ba0f13da9ad3fb12a218e02 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:24 +0000 Subject: Utilisateur : Fcolin Date : 5/02/04 Heure : 18:32 Archivé dans $/Bus/Ivy Commentaire: (vss 7) --- Ivy/DataTypes.h | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) (limited to 'Ivy') diff --git a/Ivy/DataTypes.h b/Ivy/DataTypes.h index 2267de7..daf9470 100644 --- a/Ivy/DataTypes.h +++ b/Ivy/DataTypes.h @@ -79,18 +79,21 @@ public: str.append( right.ptr, right.size); return str; } - const string& operator +=(string s) - { - return append( s.ptr, s.size ); - } - const string& operator +=(const char* s) + + void operator +=(string s) { - return append( s, strlen(s) ); + append( s.ptr, s.size ); } - const string& operator +=(char c) + + void operator +=(const char* s) { - return append( &c, 1); + append( s, strlen(s) ); } + + void operator +=(char c) + { append( &c, 1);} + + string operator +(string s) const { string str ( ptr, size ); str.append( s.ptr, s.size ); return str; } string operator +(const char c) const -- cgit v1.1 From 5d4fda6bd381bf67c37326c74abbcdd33b02f622 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:26 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 8) --- Ivy/DataTypes.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Ivy') diff --git a/Ivy/DataTypes.h b/Ivy/DataTypes.h index daf9470..c98a812 100644 --- a/Ivy/DataTypes.h +++ b/Ivy/DataTypes.h @@ -11,6 +11,9 @@ #include +namespace ivy +{ + class string { public: string(size_t len = 0) @@ -314,3 +317,4 @@ private: size_t len; }; +} \ No newline at end of file -- cgit v1.1 From 8e052a7abf762456b5794468049457335d7a4be9 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:28 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:45 Archivé dans $/Bus/Ivy Commentaire: (vss 9) --- Ivy/DataTypes.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/DataTypes.h b/Ivy/DataTypes.h index c98a812..ea17c37 100644 --- a/Ivy/DataTypes.h +++ b/Ivy/DataTypes.h @@ -142,7 +142,7 @@ protected: public: - friend class iterator; + //friend class iterator; class iterator { public: iterator() -- cgit v1.1 From 8d5a7b300f69298500e97762987ccd36174c288a Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:30 +0000 Subject: Utilisateur : Fcolin Date : 23/09/05 Heure : 15:27 Archivé dans $/Bus/Ivy Commentaire: (vss 10) --- Ivy/DataTypes.h | 31 ++++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) (limited to 'Ivy') diff --git a/Ivy/DataTypes.h b/Ivy/DataTypes.h index ea17c37..190a7a6 100644 --- a/Ivy/DataTypes.h +++ b/Ivy/DataTypes.h @@ -16,14 +16,15 @@ namespace ivy class string { public: + static const size_t npos = size_t(-1); string(size_t len = 0) { ptr = allocBuffer( len ); }; string ( const string& s ) { ptr = 0; copy( s.ptr, s.size ); } - string( const char * s, int len = -1 ) + string( const char * s, size_t len = npos ) { ptr = 0; - if ( len < 0 ) + if ( len == npos ) len = strlen(s) ; copy( s, len ); } @@ -34,17 +35,17 @@ public: { return size; } bool empty() const { return size==0; } - void copy( const char * s, int len ) + void copy( const char * s, size_t len ) { if ( ptr ) delete [] ptr; ptr = allocBuffer( len ); strncpy( ptr, s, len ); } - void erase(int start=0, int len = -1) + void erase(size_t start=0, size_t len = npos) { char *newptr; size_t real_len; - real_len = len < 0 ? size - start : len; + real_len = len == npos ? size - start : len; if ( real_len > size ) real_len = size; newptr = allocBuffer( size - real_len ); strncpy( newptr, ptr , start ); @@ -52,14 +53,14 @@ public: delete ptr; ptr = newptr; } - void append( const char *s , int len = -1 ) + void append( const char *s , size_t len = npos ) { insert ( size, s , len ); } - void insert(int index, const char * s, int len = -1) + void insert(size_t index, const char * s, size_t len = npos) { char *newptr; - if ( len < 0 ) len = strlen(s) ; + if ( len == npos ) len = strlen(s) ; newptr = allocBuffer( size + len ); strncpy( newptr , ptr, index ); strncpy( newptr+index , s, len ) ; @@ -67,12 +68,12 @@ public: delete ptr; ptr = newptr; } - string substr( int start, int len = -1 ) + string substr( size_t start, size_t len = npos ) { return string ( &ptr[start], len ); } - int find_first_of( const char* strCharSet ) - { char *fnd = strpbrk( ptr, strCharSet ); if ( fnd ) return fnd - ptr; else return -1; } - int rfind( char c ) - { char *fnd = strrchr( ptr, c); if ( fnd ) return fnd - ptr; else return -1; } + size_t find_first_of( const char* strCharSet ) + { char *fnd = strpbrk( ptr, strCharSet ); if ( fnd ) return (size_t)(fnd - ptr); else return npos; } + size_t rfind( char c ) + { char *fnd = strrchr( ptr, c); if ( fnd ) return (size_t)(fnd - ptr); else return npos; } // friend string operator + (const string& left, const char* right); // friend string operator + (const char* left, const string& right); friend string operator + (const string& left, const string& right) @@ -114,7 +115,7 @@ private: char *ptr; size_t size; // always allocate one extra character for '\0' termination - char *allocBuffer(int len) + char *allocBuffer(size_t len) { char *newptr; size = len; @@ -295,7 +296,7 @@ public: void push_back( const T& value ) { T* newdata = new T[len+1]; - for ( unsigned int i = 0; i < len ; i ++ ) + for ( size_t i = 0; i < len ; i ++ ) newdata[i] = data[i]; newdata[len++] = value; if ( data ) delete [] data; -- cgit v1.1 From e66ce001f6b6ff89fa0804d167d16e73f12a5d4b Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:32 +0000 Subject: Utilisateur : Fcolin Date : 16/11/05 Heure : 9:54 Archivé dans $/Bus/Ivy Commentaire: 64 bits ports (vss 11) --- Ivy/DataTypes.h | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) (limited to 'Ivy') diff --git a/Ivy/DataTypes.h b/Ivy/DataTypes.h index 190a7a6..280c2de 100644 --- a/Ivy/DataTypes.h +++ b/Ivy/DataTypes.h @@ -10,7 +10,7 @@ #endif #include - +#include namespace ivy { @@ -39,17 +39,19 @@ public: { if ( ptr ) delete [] ptr; ptr = allocBuffer( len ); - strncpy( ptr, s, len ); + strncpy_s( ptr, len + 1, s, len ); } void erase(size_t start=0, size_t len = npos) { char *newptr; size_t real_len; + size_t buf_size; real_len = len == npos ? size - start : len; if ( real_len > size ) real_len = size; - newptr = allocBuffer( size - real_len ); - strncpy( newptr, ptr , start ); - strncpy( &newptr[start], &ptr[start+real_len], size - start ); + buf_size = size - real_len; + newptr = allocBuffer( buf_size ); + strncpy_s( newptr, buf_size +1, ptr , start ); + strncpy_s( &newptr[start], buf_size +1 - start, &ptr[start+real_len], size - start ); delete ptr; ptr = newptr; } @@ -61,10 +63,11 @@ public: { char *newptr; if ( len == npos ) len = strlen(s) ; - newptr = allocBuffer( size + len ); - strncpy( newptr , ptr, index ); - strncpy( newptr+index , s, len ) ; - strncpy( newptr+index+len , &ptr[index], size - (index+len) ) ; + size_t buf_len = size + len; + newptr = allocBuffer( buf_len ); + strncpy_s( newptr , buf_len +1, ptr, index ); + strncpy_s( newptr+index, buf_len + 1 - index, s, len ) ; + strncpy_s( newptr+index+len, buf_len + 1 - index -len, &ptr[index], size - (index+len) ) ; delete ptr; ptr = newptr; } -- cgit v1.1 From e69d66f4d8d2871c8643d27b5fc04732826f8459 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:34 +0000 Subject: Utilisateur : Fcolin Date : 17/11/05 Heure : 15:08 Archivé dans $/Bus/Ivy Commentaire: nice Bug in nextArg not reentrant routine due to static variable (vss 12) --- Ivy/DataTypes.h | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) (limited to 'Ivy') diff --git a/Ivy/DataTypes.h b/Ivy/DataTypes.h index 280c2de..8afc4ce 100644 --- a/Ivy/DataTypes.h +++ b/Ivy/DataTypes.h @@ -1,19 +1,23 @@ #pragma once + +#include + +namespace ivy +{ #ifdef WIN32 #ifdef IVY_EXPORTS -//class _declspec(dllexport) string; +class _declspec(dllexport) string; +template class _declspec(dllexport) list; +template class _declspec(dllexport) vector; #else -//#pragma comment(lib,"Ivy.LIB" ) -//class _declspec(dllimport) string; +#pragma comment(lib,"Ivy.LIB" ) +class _declspec(dllimport) string; +template class _declspec(dllimport) list; +template class _declspec(dllimport) vector; #endif #endif -#include -#include -namespace ivy -{ - class string { public: static const size_t npos = size_t(-1); -- cgit v1.1 From 5039c1e432746a6e34d568818c8a0e1793ceef8f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:42 +0000 Subject: Utilisateur : Fcolin Date : 3/10/02 Heure : 16:11 Créé Commentaire: (vss 1) --- Ivy/InstIvy/InstIvy.sln | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 Ivy/InstIvy/InstIvy.sln (limited to 'Ivy') diff --git a/Ivy/InstIvy/InstIvy.sln b/Ivy/InstIvy/InstIvy.sln new file mode 100644 index 0000000..212066d --- /dev/null +++ b/Ivy/InstIvy/InstIvy.sln @@ -0,0 +1,32 @@ +Microsoft Visual Studio Solution File, Format Version 7.00 +Project("{54435603-DBB4-11D2-8724-00A0C9A8B90C}") = "InstIvy", "..\..\..\..\Program Files\Microsoft Visual Studio\Common\VSS\temp\InstIvy.vdproj", "{E53BCCDB-5CE7-40F8-AC36-0D304E442AB3}" +EndProject +Global + GlobalSection(SourceCodeControl) = preSolution + SccNumberOfProjects = 2 + SccProjectUniqueName0 = ..\\..\\..\\..\\Program\u0020Files\\Microsoft\u0020Visual\u0020Studio\\Common\\VSS\\temp\\InstIvy.vdproj + SccLocalPath0 = ..\\..\\..\\..\\Program\u0020Files\\Microsoft\u0020Visual\u0020Studio\\Common\\VSS\\temp + CanCheckoutShared = false + SccProjectName1 = \u0022$/Bus/Install/InstIvy\u0022,\u0020CREAAAAA + SccLocalPath1 = . + SccProvider1 = MSSCCI:Microsoft\u0020Visual\u0020SourceSafe + CanCheckoutShared = false + SolutionUniqueID = {F1027A98-11B4-463A-808C-63E2AD09C2EA} + EndGlobalSection + GlobalSection(SolutionConfiguration) = preSolution + ConfigName.0 = Debug + ConfigName.1 = Release + EndGlobalSection + GlobalSection(ProjectDependencies) = postSolution + EndGlobalSection + GlobalSection(ProjectConfiguration) = postSolution + {E53BCCDB-5CE7-40F8-AC36-0D304E442AB3}.Debug.ActiveCfg = Debug + {E53BCCDB-5CE7-40F8-AC36-0D304E442AB3}.Debug.Build.0 = Debug + {E53BCCDB-5CE7-40F8-AC36-0D304E442AB3}.Release.ActiveCfg = Release + {E53BCCDB-5CE7-40F8-AC36-0D304E442AB3}.Release.Build.0 = Release + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + EndGlobalSection + GlobalSection(ExtensibilityAddIns) = postSolution + EndGlobalSection +EndGlobal -- cgit v1.1 From b3f554a08a064410d502dde6a29242b6c45cf40a Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:43 +0000 Subject: Utilisateur : Fcolin Date : 3/10/02 Heure : 16:56 Archivé dans $/Bus/Install/InstIvy Commentaire: (vss 2) --- Ivy/InstIvy/InstIvy.sln | 32 +++++++++++++++++++++----------- 1 file changed, 21 insertions(+), 11 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstIvy/InstIvy.sln b/Ivy/InstIvy/InstIvy.sln index 212066d..def9de2 100644 --- a/Ivy/InstIvy/InstIvy.sln +++ b/Ivy/InstIvy/InstIvy.sln @@ -1,17 +1,23 @@ Microsoft Visual Studio Solution File, Format Version 7.00 -Project("{54435603-DBB4-11D2-8724-00A0C9A8B90C}") = "InstIvy", "..\..\..\..\Program Files\Microsoft Visual Studio\Common\VSS\temp\InstIvy.vdproj", "{E53BCCDB-5CE7-40F8-AC36-0D304E442AB3}" +Project("{54435603-DBB4-11D2-8724-00A0C9A8B90C}") = "InstIvy", "InstIvy.vdproj", "{8826FCA8-62E5-449E-A1F5-A3203F13EF78}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Ivy", "..\..\C++\Bus\Ivy\Ivy.vcproj", "{9F40EF6B-8C74-4087-9E25-32A5E7EC2128}" EndProject Global GlobalSection(SourceCodeControl) = preSolution - SccNumberOfProjects = 2 - SccProjectUniqueName0 = ..\\..\\..\\..\\Program\u0020Files\\Microsoft\u0020Visual\u0020Studio\\Common\\VSS\\temp\\InstIvy.vdproj - SccLocalPath0 = ..\\..\\..\\..\\Program\u0020Files\\Microsoft\u0020Visual\u0020Studio\\Common\\VSS\\temp + SccNumberOfProjects = 3 + SccProjectName0 = \u0022$/Bus/Install/InstIvy\u0022,\u0020CREAAAAA + SccLocalPath0 = . + SccProvider0 = MSSCCI:Microsoft\u0020Visual\u0020SourceSafe CanCheckoutShared = false - SccProjectName1 = \u0022$/Bus/Install/InstIvy\u0022,\u0020CREAAAAA + SolutionUniqueID = {F1027A98-11B4-463A-808C-63E2AD09C2EA} + SccProjectUniqueName1 = InstIvy.vdproj SccLocalPath1 = . - SccProvider1 = MSSCCI:Microsoft\u0020Visual\u0020SourceSafe CanCheckoutShared = false - SolutionUniqueID = {F1027A98-11B4-463A-808C-63E2AD09C2EA} + SccProjectUniqueName2 = ..\\..\\C++\\Bus\\Ivy\\Ivy.vcproj + SccProjectName2 = \u0022$/Bus/Ivy\u0022,\u0020QPEAAAAA + SccLocalPath2 = ..\\..\\C++\\Bus\\Ivy + CanCheckoutShared = false EndGlobalSection GlobalSection(SolutionConfiguration) = preSolution ConfigName.0 = Debug @@ -20,10 +26,14 @@ Global GlobalSection(ProjectDependencies) = postSolution EndGlobalSection GlobalSection(ProjectConfiguration) = postSolution - {E53BCCDB-5CE7-40F8-AC36-0D304E442AB3}.Debug.ActiveCfg = Debug - {E53BCCDB-5CE7-40F8-AC36-0D304E442AB3}.Debug.Build.0 = Debug - {E53BCCDB-5CE7-40F8-AC36-0D304E442AB3}.Release.ActiveCfg = Release - {E53BCCDB-5CE7-40F8-AC36-0D304E442AB3}.Release.Build.0 = Release + {8826FCA8-62E5-449E-A1F5-A3203F13EF78}.Debug.ActiveCfg = Debug + {8826FCA8-62E5-449E-A1F5-A3203F13EF78}.Debug.Build.0 = Debug + {8826FCA8-62E5-449E-A1F5-A3203F13EF78}.Release.ActiveCfg = Release + {8826FCA8-62E5-449E-A1F5-A3203F13EF78}.Release.Build.0 = Release + {9F40EF6B-8C74-4087-9E25-32A5E7EC2128}.Debug.ActiveCfg = Debug|Win32 + {9F40EF6B-8C74-4087-9E25-32A5E7EC2128}.Debug.Build.0 = Debug|Win32 + {9F40EF6B-8C74-4087-9E25-32A5E7EC2128}.Release.ActiveCfg = Release|Win32 + {9F40EF6B-8C74-4087-9E25-32A5E7EC2128}.Release.Build.0 = Release|Win32 EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution EndGlobalSection -- cgit v1.1 From f8fdfba5a57665f623859999b526df40df4645d6 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:45 +0000 Subject: Utilisateur : Fcolin Date : 3/10/02 Heure : 10:54 Créé Commentaire: (vss 1) --- Ivy/InstIvy/InstIvy.vdproj | 190 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 190 insertions(+) create mode 100644 Ivy/InstIvy/InstIvy.vdproj (limited to 'Ivy') diff --git a/Ivy/InstIvy/InstIvy.vdproj b/Ivy/InstIvy/InstIvy.vdproj new file mode 100644 index 0000000..3c57564 --- /dev/null +++ b/Ivy/InstIvy/InstIvy.vdproj @@ -0,0 +1,190 @@ +"DeployProject" +{ +"VSVersion" = "3:700" +"ProjectType" = "8:{5443560e-dbb4-11d2-8724-00a0c9a8b90c}" +"IsWebType" = "8:FALSE" +"ProjectName" = "8:InstIvy" +"LanguageId" = "3:1036" +"CodePage" = "3:1252" +"UILanguageId" = "3:1036" +"SccProjectName" = "8:\"$/fcolin\", SPEAAAAA" +"SccLocalPath" = "8:..\\.." +"SccAuxPath" = "8:" +"SccProvider" = "8:MSSCCI:Microsoft Visual SourceSafe" + "Hierarchy" + { + "Entry" + { + "MsmKey" = "8:_E9F23F82D12A4D518B138018AD21A5C7" + "OwnerKey" = "8:_UNDEFINED" + "MsmSig" = "8:C:\\USERS\\FCOLIN\\PROGRAM FILES\\DEBUG\\IVY.DLL" + } + } + "Configurations" + { + "Debug" + { + "DisplayName" = "8:Debug" + "IsDebugOnly" = "11:TRUE" + "IsReleaseOnly" = "11:FALSE" + "OutputFilename" = "8:Debug\\InstIvy.msm" + "PackageFilesAs" = "3:2" + "PackageFileSize" = "3:-2147483648" + "CabType" = "3:1" + "Compression" = "3:2" + "SignOutput" = "11:FALSE" + "CertificateFile" = "8:" + "PrivateKeyFile" = "8:" + "TimeStampServer" = "8:" + "InstallerBootstrapper" = "3:1" + } + "Release" + { + "DisplayName" = "8:Release" + "IsDebugOnly" = "11:FALSE" + "IsReleaseOnly" = "11:TRUE" + "OutputFilename" = "8:Release\\InstIvy.msm" + "PackageFilesAs" = "3:2" + "PackageFileSize" = "3:-2147483648" + "CabType" = "3:1" + "Compression" = "3:2" + "SignOutput" = "11:FALSE" + "CertificateFile" = "8:" + "PrivateKeyFile" = "8:" + "TimeStampServer" = "8:" + "InstallerBootstrapper" = "3:1" + } + } + "Deployable" + { + "CustomAction" + { + } + "DefaultFeature" + { + "Name" = "8:DefaultFeature" + "Title" = "8:" + "Description" = "8:" + } + "File" + { + } + "FileType" + { + } + "Folder" + { + "{2FBCB9FF-B6A1-4FA9-9C7C-D1366E178586}:_7BEBD1D67A934D228BFBAE7C11467C9A" + { + "DefaultLocation" = "8:[TARGETDIR]" + "DisplayName" = "8:Dossier Remplacement pour les modules" + "Description" = "8:" + "Name" = "8:Dossier Remplacement pour les modules" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:NEWRETARGETABLEPROPERTY1" + "Folders" + { + } + } + "{777C097F-0ED8-11D3-8D6C-00A0C9CFCEE6}:_95C620F5C6F34995951BBCEA2FDF6B8C" + { + "Name" = "8:#1910" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:CommonFilesFolder" + "Folders" + { + } + } + } + "Shortcut" + { + } + "Sequences" + { + } + "Registry" + { + "HKLM" + { + "Keys" + { + } + } + "HKCU" + { + "Keys" + { + } + } + "HKCR" + { + "Keys" + { + } + } + "HKU" + { + "Keys" + { + } + } + "HKPU" + { + "Keys" + { + } + } + } + "ProjectOutput" + { + "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_E9F23F82D12A4D518B138018AD21A5C7" + { + "SourcePath" = "8:..\\..\\Program Files\\Debug\\Ivy.dll" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_95C620F5C6F34995951BBCEA2FDF6B8C" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:Built" + "OutputProjectCanonicalName" = "8:..\\..\\C++\\Bus\\Ivy\\Ivy.vcproj" + "OutputProjectGuid" = "8:{9818D652-CC05-463E-880D-AFCA2C7BFABE}" + "ShowKeyOutput" = "11:FALSE" + "ExcludeFilters" + { + } + } + } + "Module" + { + "ModuleSignature" = "8:MergeModule.50212549D8E242BBB1C9246BFDAFADB2" + "Version" = "8:1.0.0.0" + "Title" = "8:Ivy" + "Subject" = "8:" + "Author" = "8:CENA" + "Keywords" = "8:" + "Comments" = "8:" + "SearchPath" = "8:" + "UseSystemSearchPath" = "11:TRUE" + } + "MergeModule" + { + } + } +} -- cgit v1.1 From b51ce334270c4989326a2174f9f4d5a3c2db8719 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:47 +0000 Subject: Utilisateur : Fcolin Date : 3/10/02 Heure : 12:09 Archivé dans $/fcolin/Install/InstIvy Commentaire: (vss 2) --- Ivy/InstIvy/InstIvy.vdproj | 209 +++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 201 insertions(+), 8 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstIvy/InstIvy.vdproj b/Ivy/InstIvy/InstIvy.vdproj index 3c57564..c1b3e61 100644 --- a/Ivy/InstIvy/InstIvy.vdproj +++ b/Ivy/InstIvy/InstIvy.vdproj @@ -15,10 +15,58 @@ { "Entry" { - "MsmKey" = "8:_E9F23F82D12A4D518B138018AD21A5C7" + "MsmKey" = "8:_2409E7519F5058B9E967379542A95097" + "OwnerKey" = "8:_BAA443135CA14A7E81EB7A52F5A18EE0" + "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\MSVCP70D.DLL" + } + "Entry" + { + "MsmKey" = "8:_5007A5EA0EE84C13BB6B31EB6F74CB2C" + "OwnerKey" = "8:_E4F14818A088497C83716F25194F0014" + "MsmSig" = "8:C:\\USERS\\FCOLIN\\PROGRAM FILES\\DEBUG\\IVY.DLL" + } + "Entry" + { + "MsmKey" = "8:_AB0CB817E553832FDD27DD3AAC1EBC00" + "OwnerKey" = "8:_E4F14818A088497C83716F25194F0014" + "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\MFC70D.DLL" + } + "Entry" + { + "MsmKey" = "8:_BAA443135CA14A7E81EB7A52F5A18EE0" "OwnerKey" = "8:_UNDEFINED" "MsmSig" = "8:C:\\USERS\\FCOLIN\\PROGRAM FILES\\DEBUG\\IVY.DLL" } + "Entry" + { + "MsmKey" = "8:_DEA45E14BA5E11950E31ADEE63118ACB" + "OwnerKey" = "8:_BAA443135CA14A7E81EB7A52F5A18EE0" + "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\MSVCR70D.DLL" + } + "Entry" + { + "MsmKey" = "8:_DEA45E14BA5E11950E31ADEE63118ACB" + "OwnerKey" = "8:_E4F14818A088497C83716F25194F0014" + "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\MSVCR70D.DLL" + } + "Entry" + { + "MsmKey" = "8:_E3EAD04FF43E53C785D576930F186E2B" + "OwnerKey" = "8:_BAA443135CA14A7E81EB7A52F5A18EE0" + "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\WSOCK32.DLL" + } + "Entry" + { + "MsmKey" = "8:_E3EAD04FF43E53C785D576930F186E2B" + "OwnerKey" = "8:_E4F14818A088497C83716F25194F0014" + "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\WSOCK32.DLL" + } + "Entry" + { + "MsmKey" = "8:_E4F14818A088497C83716F25194F0014" + "OwnerKey" = "8:_UNDEFINED" + "MsmSig" = "8:C:\\USERS\\FCOLIN\\PROGRAM FILES\\DEBUG\\IVYPROBE.EXE" + } } "Configurations" { @@ -68,12 +116,128 @@ } "File" { + "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_2409E7519F5058B9E967379542A95097" + { + "Signature" = "8:2000000090c39d10d295c1010802179dc26ac20190c39d10d295c1010000000000400b0000000000000000006d0073007600630070003700300064002e0064006c006c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" + "SourcePath" = "8:MSVCP70D.dll" + "TargetName" = "8:MSVCP70D.dll" + "Tag" = "8:" + "Folder" = "8:_15DCD27905D341429030EE4BA476A488" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:TRUE" + "IsolateTo" = "8:" + } + "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_5007A5EA0EE84C13BB6B31EB6F74CB2C" + { + "Signature" = "8:200000008da832e3bf6ac2018da832e3bf6ac201d9df8ae3bf6ac2010000000000e0020000000000000000004900760079002e0064006c006c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" + "SourcePath" = "8:Ivy.dll" + "TargetName" = "8:Ivy.dll" + "Tag" = "8:" + "Folder" = "8:_15DCD27905D341429030EE4BA476A488" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:TRUE" + "IsolateTo" = "8:" + } + "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_AB0CB817E553832FDD27DD3AAC1EBC00" + { + "Signature" = "8:2000000090eab8acdf95c1014e50259dc26ac20190eab8acdf95c1010000000000801d0000000000000000006d00660063003700300064002e0064006c006c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" + "SourcePath" = "8:MFC70D.DLL" + "TargetName" = "8:MFC70D.DLL" + "Tag" = "8:" + "Folder" = "8:_15DCD27905D341429030EE4BA476A488" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:4" + "Exclude" = "11:FALSE" + "IsDependency" = "11:TRUE" + "IsolateTo" = "8:" + } + "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_DEA45E14BA5E11950E31ADEE63118ACB" + { + "Signature" = "8:20000000a04c53fed195c1010802179dc26ac201a04c53fed195c101000000000030080000000000000000006d0073007600630072003700300064002e0064006c006c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" + "SourcePath" = "8:MSVCR70D.dll" + "TargetName" = "8:MSVCR70D.dll" + "Tag" = "8:" + "Folder" = "8:_15DCD27905D341429030EE4BA476A488" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:TRUE" + "IsolateTo" = "8:" + } + "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_E3EAD04FF43E53C785D576930F186E2B" + { + "Signature" = "8:2000000000e08cf6b82fc101360d04f2bc6ac20100e08cf6b82fc10100000000005e00000000000000000000770073006f0063006b00330032002e0064006c006c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" + "SourcePath" = "8:WSOCK32.dll" + "TargetName" = "8:WSOCK32.dll" + "Tag" = "8:" + "Folder" = "8:_15DCD27905D341429030EE4BA476A488" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:TRUE" + "IsolateTo" = "8:" + } } "FileType" { } "Folder" { + "{777C097F-0ED8-11D3-8D6C-00A0C9CFCEE6}:_15DCD27905D341429030EE4BA476A488" + { + "Name" = "8:#1910" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:CommonFilesFolder" + "Folders" + { + } + } "{2FBCB9FF-B6A1-4FA9-9C7C-D1366E178586}:_7BEBD1D67A934D228BFBAE7C11467C9A" { "DefaultLocation" = "8:[TARGETDIR]" @@ -88,13 +252,13 @@ { } } - "{777C097F-0ED8-11D3-8D6C-00A0C9CFCEE6}:_95C620F5C6F34995951BBCEA2FDF6B8C" + "{777C097F-0ED8-11D3-8D6C-00A0C9CFCEE6}:_AEEFF3D8A3364088A698304D464E078E" { - "Name" = "8:#1910" + "Name" = "8:#1914" "AlwaysCreate" = "11:FALSE" "Condition" = "8:" "Transitive" = "11:FALSE" - "Property" = "8:CommonFilesFolder" + "Property" = "8:SystemFolder" "Folders" { } @@ -141,12 +305,41 @@ } "ProjectOutput" { - "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_E9F23F82D12A4D518B138018AD21A5C7" + "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_BAA443135CA14A7E81EB7A52F5A18EE0" { "SourcePath" = "8:..\\..\\Program Files\\Debug\\Ivy.dll" "TargetName" = "8:" "Tag" = "8:" - "Folder" = "8:_95C620F5C6F34995951BBCEA2FDF6B8C" + "Folder" = "8:_15DCD27905D341429030EE4BA476A488" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:Built" + "OutputProjectCanonicalName" = "8:Ivy\\Ivy.vcproj" + "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" + "ShowKeyOutput" = "11:FALSE" + "ExcludeFilters" + { + } + } + "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_E4F14818A088497C83716F25194F0014" + { + "SourcePath" = "8:..\\..\\Program Files\\Debug\\IvyProbe.exe" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_15DCD27905D341429030EE4BA476A488" "Condition" = "8:" "Transitive" = "11:FALSE" "Vital" = "11:TRUE" @@ -163,8 +356,8 @@ "ProjectOutputGroupRegister" = "3:1" "OutputConfiguration" = "8:" "OutputGroupCanonicalName" = "8:Built" - "OutputProjectCanonicalName" = "8:..\\..\\C++\\Bus\\Ivy\\Ivy.vcproj" - "OutputProjectGuid" = "8:{9818D652-CC05-463E-880D-AFCA2C7BFABE}" + "OutputProjectCanonicalName" = "8:Test\\Test.vcproj" + "OutputProjectGuid" = "8:{BBC2E9DE-EC32-4F3B-9BD9-C6E7C52B6AF9}" "ShowKeyOutput" = "11:FALSE" "ExcludeFilters" { -- cgit v1.1 From 69da8670875420110989213ff89cfea36073faa2 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:49 +0000 Subject: Utilisateur : Fcolin Date : 3/10/02 Heure : 16:38 Archivé dans $/Bus/Install/InstIvy Commentaire: (vss 3) --- Ivy/InstIvy/InstIvy.vdproj | 147 +++++++-------------------------------------- 1 file changed, 23 insertions(+), 124 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstIvy/InstIvy.vdproj b/Ivy/InstIvy/InstIvy.vdproj index c1b3e61..4346312 100644 --- a/Ivy/InstIvy/InstIvy.vdproj +++ b/Ivy/InstIvy/InstIvy.vdproj @@ -7,66 +7,36 @@ "LanguageId" = "3:1036" "CodePage" = "3:1252" "UILanguageId" = "3:1036" -"SccProjectName" = "8:\"$/fcolin\", SPEAAAAA" -"SccLocalPath" = "8:..\\.." +"SccProjectName" = "8:\"$/Bus/Install/InstIvy\", CREAAAAA" +"SccLocalPath" = "8:." "SccAuxPath" = "8:" "SccProvider" = "8:MSSCCI:Microsoft Visual SourceSafe" "Hierarchy" { "Entry" { - "MsmKey" = "8:_2409E7519F5058B9E967379542A95097" - "OwnerKey" = "8:_BAA443135CA14A7E81EB7A52F5A18EE0" - "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\MSVCP70D.DLL" - } - "Entry" - { - "MsmKey" = "8:_5007A5EA0EE84C13BB6B31EB6F74CB2C" - "OwnerKey" = "8:_E4F14818A088497C83716F25194F0014" - "MsmSig" = "8:C:\\USERS\\FCOLIN\\PROGRAM FILES\\DEBUG\\IVY.DLL" - } - "Entry" - { - "MsmKey" = "8:_AB0CB817E553832FDD27DD3AAC1EBC00" - "OwnerKey" = "8:_E4F14818A088497C83716F25194F0014" - "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\MFC70D.DLL" - } - "Entry" - { - "MsmKey" = "8:_BAA443135CA14A7E81EB7A52F5A18EE0" + "MsmKey" = "8:_1C8127E2CE08470A9FB2772F59EF6C16" "OwnerKey" = "8:_UNDEFINED" "MsmSig" = "8:C:\\USERS\\FCOLIN\\PROGRAM FILES\\DEBUG\\IVY.DLL" } "Entry" { - "MsmKey" = "8:_DEA45E14BA5E11950E31ADEE63118ACB" - "OwnerKey" = "8:_BAA443135CA14A7E81EB7A52F5A18EE0" + "MsmKey" = "8:_474D2E042D971A73B3B54FD999910DF8" + "OwnerKey" = "8:_1C8127E2CE08470A9FB2772F59EF6C16" "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\MSVCR70D.DLL" } "Entry" { - "MsmKey" = "8:_DEA45E14BA5E11950E31ADEE63118ACB" - "OwnerKey" = "8:_E4F14818A088497C83716F25194F0014" - "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\MSVCR70D.DLL" - } - "Entry" - { - "MsmKey" = "8:_E3EAD04FF43E53C785D576930F186E2B" - "OwnerKey" = "8:_BAA443135CA14A7E81EB7A52F5A18EE0" - "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\WSOCK32.DLL" + "MsmKey" = "8:_6853BE42500AB02614E13C492A847CC2" + "OwnerKey" = "8:_1C8127E2CE08470A9FB2772F59EF6C16" + "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\MSVCP70D.DLL" } "Entry" { - "MsmKey" = "8:_E3EAD04FF43E53C785D576930F186E2B" - "OwnerKey" = "8:_E4F14818A088497C83716F25194F0014" + "MsmKey" = "8:_84E197CA5A09A6E635F4F2D20CB9C269" + "OwnerKey" = "8:_1C8127E2CE08470A9FB2772F59EF6C16" "MsmSig" = "8:C:\\WINDOWS\\SYSTEM32\\WSOCK32.DLL" } - "Entry" - { - "MsmKey" = "8:_E4F14818A088497C83716F25194F0014" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:C:\\USERS\\FCOLIN\\PROGRAM FILES\\DEBUG\\IVYPROBE.EXE" - } } "Configurations" { @@ -116,32 +86,11 @@ } "File" { - "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_2409E7519F5058B9E967379542A95097" - { - "Signature" = "8:2000000090c39d10d295c1010802179dc26ac20190c39d10d295c1010000000000400b0000000000000000006d0073007600630070003700300064002e0064006c006c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" - "SourcePath" = "8:MSVCP70D.dll" - "TargetName" = "8:MSVCP70D.dll" - "Tag" = "8:" - "Folder" = "8:_15DCD27905D341429030EE4BA476A488" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:TRUE" - "IsolateTo" = "8:" - } - "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_5007A5EA0EE84C13BB6B31EB6F74CB2C" + "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_474D2E042D971A73B3B54FD999910DF8" { - "Signature" = "8:200000008da832e3bf6ac2018da832e3bf6ac201d9df8ae3bf6ac2010000000000e0020000000000000000004900760079002e0064006c006c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" - "SourcePath" = "8:Ivy.dll" - "TargetName" = "8:Ivy.dll" + "Signature" = "8:20000000a04c53fed195c101662efae5e36ac201a04c53fed195c101000000000030080000000000000000006d0073007600630072003700300064002e0064006c006c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" + "SourcePath" = "8:MSVCR70D.dll" + "TargetName" = "8:MSVCR70D.dll" "Tag" = "8:" "Folder" = "8:_15DCD27905D341429030EE4BA476A488" "Condition" = "8:" @@ -158,32 +107,11 @@ "IsDependency" = "11:TRUE" "IsolateTo" = "8:" } - "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_AB0CB817E553832FDD27DD3AAC1EBC00" + "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_6853BE42500AB02614E13C492A847CC2" { - "Signature" = "8:2000000090eab8acdf95c1014e50259dc26ac20190eab8acdf95c1010000000000801d0000000000000000006d00660063003700300064002e0064006c006c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" - "SourcePath" = "8:MFC70D.DLL" - "TargetName" = "8:MFC70D.DLL" - "Tag" = "8:" - "Folder" = "8:_15DCD27905D341429030EE4BA476A488" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:4" - "Exclude" = "11:FALSE" - "IsDependency" = "11:TRUE" - "IsolateTo" = "8:" - } - "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_DEA45E14BA5E11950E31ADEE63118ACB" - { - "Signature" = "8:20000000a04c53fed195c1010802179dc26ac201a04c53fed195c101000000000030080000000000000000006d0073007600630072003700300064002e0064006c006c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" - "SourcePath" = "8:MSVCR70D.dll" - "TargetName" = "8:MSVCR70D.dll" + "Signature" = "8:2000000090c39d10d295c101662efae5e36ac20190c39d10d295c1010000000000400b0000000000000000006d0073007600630070003700300064002e0064006c006c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" + "SourcePath" = "8:MSVCP70D.dll" + "TargetName" = "8:MSVCP70D.dll" "Tag" = "8:" "Folder" = "8:_15DCD27905D341429030EE4BA476A488" "Condition" = "8:" @@ -200,9 +128,9 @@ "IsDependency" = "11:TRUE" "IsolateTo" = "8:" } - "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_E3EAD04FF43E53C785D576930F186E2B" + "{54DA9790-1474-11D3-8E00-00C04F6837D0}:_84E197CA5A09A6E635F4F2D20CB9C269" { - "Signature" = "8:2000000000e08cf6b82fc101360d04f2bc6ac20100e08cf6b82fc10100000000005e00000000000000000000770073006f0063006b00330032002e0064006c006c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" + "Signature" = "8:2000000000e08cf6b82fc101bec8e082ea6ac20100e08cf6b82fc10100000000005e00000000000000000000770073006f0063006b00330032002e0064006c006c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" "SourcePath" = "8:WSOCK32.dll" "TargetName" = "8:WSOCK32.dll" "Tag" = "8:" @@ -305,7 +233,7 @@ } "ProjectOutput" { - "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_BAA443135CA14A7E81EB7A52F5A18EE0" + "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_1C8127E2CE08470A9FB2772F59EF6C16" { "SourcePath" = "8:..\\..\\Program Files\\Debug\\Ivy.dll" "TargetName" = "8:" @@ -327,37 +255,8 @@ "ProjectOutputGroupRegister" = "3:1" "OutputConfiguration" = "8:" "OutputGroupCanonicalName" = "8:Built" - "OutputProjectCanonicalName" = "8:Ivy\\Ivy.vcproj" - "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" - "ShowKeyOutput" = "11:FALSE" - "ExcludeFilters" - { - } - } - "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_E4F14818A088497C83716F25194F0014" - { - "SourcePath" = "8:..\\..\\Program Files\\Debug\\IvyProbe.exe" - "TargetName" = "8:" - "Tag" = "8:" - "Folder" = "8:_15DCD27905D341429030EE4BA476A488" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - "ProjectOutputGroupRegister" = "3:1" - "OutputConfiguration" = "8:" - "OutputGroupCanonicalName" = "8:Built" - "OutputProjectCanonicalName" = "8:Test\\Test.vcproj" - "OutputProjectGuid" = "8:{BBC2E9DE-EC32-4F3B-9BD9-C6E7C52B6AF9}" + "OutputProjectCanonicalName" = "8:..\\..\\C++\\Bus\\Ivy\\Ivy.vcproj" + "OutputProjectGuid" = "8:{9F40EF6B-8C74-4087-9E25-32A5E7EC2128}" "ShowKeyOutput" = "11:FALSE" "ExcludeFilters" { -- cgit v1.1 From 2018775958e289c8a4fd63ceafcdf8dfa85ab871 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:51 +0000 Subject: Utilisateur : Fcolin Date : 3/10/02 Heure : 10:54 Créé Commentaire: (vss 1) --- Ivy/InstIvy/InstIvy.vdproj.vspscc | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 Ivy/InstIvy/InstIvy.vdproj.vspscc (limited to 'Ivy') diff --git a/Ivy/InstIvy/InstIvy.vdproj.vspscc b/Ivy/InstIvy/InstIvy.vdproj.vspscc new file mode 100644 index 0000000..492cf62 --- /dev/null +++ b/Ivy/InstIvy/InstIvy.vdproj.vspscc @@ -0,0 +1,10 @@ +"" +{ +"FILE_VERSION" = "9237" +"ENLISTMENT_CHOICE" = "NEVER" +"PROJECT_FILE_RELATIVE_PATH" = "relative:Install\\InstIvy" +"NUMBER_OF_EXCLUDED_FILES" = "0" +"ORIGINAL_PROJECT_FILE_PATH" = "" +"NUMBER_OF_NESTED_PROJECTS" = "0" +"SOURCE_CONTROL_SETTINGS_PROVIDER" = "PROJECT" +} -- cgit v1.1 From 8d0c3984bd732294ac6b8afbaafa888d051f13a9 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:53 +0000 Subject: Utilisateur : Fcolin Date : 3/10/02 Heure : 16:11 Créé Commentaire: (vss 1) --- Ivy/InstIvy/InstIvy.vssscc | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 Ivy/InstIvy/InstIvy.vssscc (limited to 'Ivy') diff --git a/Ivy/InstIvy/InstIvy.vssscc b/Ivy/InstIvy/InstIvy.vssscc new file mode 100644 index 0000000..794f014 --- /dev/null +++ b/Ivy/InstIvy/InstIvy.vssscc @@ -0,0 +1,10 @@ +"" +{ +"FILE_VERSION" = "9237" +"ENLISTMENT_CHOICE" = "NEVER" +"PROJECT_FILE_RELATIVE_PATH" = "" +"NUMBER_OF_EXCLUDED_FILES" = "0" +"ORIGINAL_PROJECT_FILE_PATH" = "" +"NUMBER_OF_NESTED_PROJECTS" = "0" +"SOURCE_CONTROL_SETTINGS_PROVIDER" = "PROJECT" +} -- cgit v1.1 From 16ee7a0da429ed2bd8e573fbf4c6d7e643da2a32 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:55 +0000 Subject: Utilisateur : Fcolin Date : 3/10/02 Heure : 16:50 Créé Commentaire: (vss 1) --- Ivy/InstIvyDev/InstIvyDev.sln | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 Ivy/InstIvyDev/InstIvyDev.sln (limited to 'Ivy') diff --git a/Ivy/InstIvyDev/InstIvyDev.sln b/Ivy/InstIvyDev/InstIvyDev.sln new file mode 100644 index 0000000..79e9200 --- /dev/null +++ b/Ivy/InstIvyDev/InstIvyDev.sln @@ -0,0 +1,21 @@ +Microsoft Visual Studio Solution File, Format Version 7.00 +Project("{54435603-DBB4-11D2-8724-00A0C9A8B90C}") = "InstIvyDev", "InstIvyDev.vdproj", "{07B35ABB-D1C2-4546-8ABA-945C1E8A88FE}" +EndProject +Global + GlobalSection(SolutionConfiguration) = preSolution + ConfigName.0 = Debug + ConfigName.1 = Release + EndGlobalSection + GlobalSection(ProjectDependencies) = postSolution + EndGlobalSection + GlobalSection(ProjectConfiguration) = postSolution + {07B35ABB-D1C2-4546-8ABA-945C1E8A88FE}.Debug.ActiveCfg = Debug + {07B35ABB-D1C2-4546-8ABA-945C1E8A88FE}.Debug.Build.0 = Debug + {07B35ABB-D1C2-4546-8ABA-945C1E8A88FE}.Release.ActiveCfg = Release + {07B35ABB-D1C2-4546-8ABA-945C1E8A88FE}.Release.Build.0 = Release + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + EndGlobalSection + GlobalSection(ExtensibilityAddIns) = postSolution + EndGlobalSection +EndGlobal -- cgit v1.1 From 8c89464de069dab29e1ee1b6d9c27d6f34ea7177 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:58 +0000 Subject: Utilisateur : Fcolin Date : 3/10/02 Heure : 12:09 Créé Commentaire: (vss 1) --- Ivy/InstIvyDev/InstIvyDev.vdproj | 790 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 790 insertions(+) create mode 100644 Ivy/InstIvyDev/InstIvyDev.vdproj (limited to 'Ivy') diff --git a/Ivy/InstIvyDev/InstIvyDev.vdproj b/Ivy/InstIvyDev/InstIvyDev.vdproj new file mode 100644 index 0000000..8b009f5 --- /dev/null +++ b/Ivy/InstIvyDev/InstIvyDev.vdproj @@ -0,0 +1,790 @@ +"DeployProject" +{ +"VSVersion" = "3:700" +"ProjectType" = "8:{5443560c-dbb4-11d2-8724-00a0c9a8b90c}" +"IsWebType" = "8:FALSE" +"ProjectName" = "8:InstIvyDev" +"LanguageId" = "3:1036" +"CodePage" = "3:1252" +"UILanguageId" = "3:1036" +"SccProjectName" = "8:\"$/Bus/InstIvyDev\", VQEAAAAA" +"SccLocalPath" = "8:." +"SccAuxPath" = "8:" +"SccProvider" = "8:MSSCCI:Microsoft Visual SourceSafe" + "Hierarchy" + { + "Entry" + { + "MsmKey" = "8:_49CA588930534433BBD092FF33483A60" + "OwnerKey" = "8:_UNDEFINED" + "MsmSig" = "8:MergeModule.50212549D8E242BBB1C9246BFDAFADB2" + } + } + "Configurations" + { + "Debug" + { + "DisplayName" = "8:Debug" + "IsDebugOnly" = "11:TRUE" + "IsReleaseOnly" = "11:FALSE" + "OutputFilename" = "8:Debug\\InstIvyDev.msi" + "PackageFilesAs" = "3:2" + "PackageFileSize" = "3:-2147483648" + "CabType" = "3:1" + "Compression" = "3:2" + "SignOutput" = "11:FALSE" + "CertificateFile" = "8:" + "PrivateKeyFile" = "8:" + "TimeStampServer" = "8:" + "InstallerBootstrapper" = "3:1" + } + "Release" + { + "DisplayName" = "8:Release" + "IsDebugOnly" = "11:FALSE" + "IsReleaseOnly" = "11:TRUE" + "OutputFilename" = "8:Release\\InstIvyDev.msi" + "PackageFilesAs" = "3:2" + "PackageFileSize" = "3:-2147483648" + "CabType" = "3:1" + "Compression" = "3:2" + "SignOutput" = "11:FALSE" + "CertificateFile" = "8:" + "PrivateKeyFile" = "8:" + "TimeStampServer" = "8:" + "InstallerBootstrapper" = "3:2" + } + } + "Deployable" + { + "CustomAction" + { + } + "DefaultFeature" + { + "Name" = "8:DefaultFeature" + "Title" = "8:" + "Description" = "8:" + } + "Feature" + { + } + "File" + { + } + "FileType" + { + } + "Folder" + { + "{777C097F-0ED8-11D3-8D6C-00A0C9CFCEE6}:_4BD15901AAC84D5990E88963A8C59F03" + { + "Name" = "8:#1919" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:ProgramMenuFolder" + "Folders" + { + } + } + "{777C097F-0ED8-11D3-8D6C-00A0C9CFCEE6}:_6D7C73BF0915401FBCAE371A6B43BDC4" + { + "Name" = "8:#1916" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:DesktopFolder" + "Folders" + { + } + } + "{EE62640D-12F2-11D3-8D6C-00A0C9CFCEE6}:_97BD9053CEE5430F9BC907C244C522C0" + { + "DefaultLocation" = "8:[ProgramFilesFolder][Manufacturer]\\[ProductName]" + "Name" = "8:#1925" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:TARGETDIR" + "Folders" + { + "{461E96AF-1495-11D3-8D6C-00A0C9CFCEE6}:_4BD06D3C92334052AE64EABA3DE642C3" + { + "Name" = "8:Lib" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:_884F08395AE541928DAABB355DC3485B" + "Folders" + { + } + } + "{461E96AF-1495-11D3-8D6C-00A0C9CFCEE6}:_64AFC2E36B5346C08FF007A580F68304" + { + "Name" = "8:Include" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:_631518C84C224AE680C352EB2F43713C" + "Folders" + { + } + } + "{461E96AF-1495-11D3-8D6C-00A0C9CFCEE6}:_823268F0927E471C9AC8D4518AB6C2F5" + { + "Name" = "8:SrcExample" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:_D2C6F66A7FE9467184E94EAE96D06FA2" + "Folders" + { + } + } + "{461E96AF-1495-11D3-8D6C-00A0C9CFCEE6}:_9CFE50635C5443E68113471C7E3235C3" + { + "Name" = "8:SrcLib" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:_A82ABE6889AF4890A9FB2AE77868B9D4" + "Folders" + { + } + } + } + } + } + "LaunchCondition" + { + } + "Locator" + { + } + "Shortcut" + { + } + "Sequences" + { + } + "Registry" + { + "HKLM" + { + "Keys" + { + "{7DF0CD0A-FF27-11D2-8D6B-00A0C9CFCEE6}:_BB28EFBCAF6D427984A8D12ADA79ED71" + { + "Name" = "8:Software" + "Condition" = "8:" + "AlwaysCreate" = "11:FALSE" + "DeleteAtUninstall" = "11:FALSE" + "Transitive" = "11:FALSE" + "Keys" + { + "{7DF0CD0A-FF27-11D2-8D6B-00A0C9CFCEE6}:_46BB5FEDD5E54B1DA83F1AEE69B7414D" + { + "Name" = "8:[Manufacturer]" + "Condition" = "8:" + "AlwaysCreate" = "11:FALSE" + "DeleteAtUninstall" = "11:FALSE" + "Transitive" = "11:FALSE" + "Keys" + { + } + "Values" + { + } + } + } + "Values" + { + } + } + } + } + "HKCU" + { + "Keys" + { + "{7DF0CD0A-FF27-11D2-8D6B-00A0C9CFCEE6}:_D254D89ED3C54FA68FAE6AD35F7725E3" + { + "Name" = "8:Software" + "Condition" = "8:" + "AlwaysCreate" = "11:FALSE" + "DeleteAtUninstall" = "11:FALSE" + "Transitive" = "11:FALSE" + "Keys" + { + "{7DF0CD0A-FF27-11D2-8D6B-00A0C9CFCEE6}:_D96808EDD7E448E3BF4976DBB5153FDA" + { + "Name" = "8:[Manufacturer]" + "Condition" = "8:" + "AlwaysCreate" = "11:FALSE" + "DeleteAtUninstall" = "11:FALSE" + "Transitive" = "11:FALSE" + "Keys" + { + } + "Values" + { + } + } + } + "Values" + { + } + } + } + } + "HKCR" + { + "Keys" + { + } + } + "HKU" + { + "Keys" + { + } + } + "HKPU" + { + "Keys" + { + } + } + } + "ProjectOutput" + { + "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_3443BE23ACC842AB8885E291A36FEB88" + { + "SourcePath" = "8:" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_4BD06D3C92334052AE64EABA3DE642C3" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:TRUE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:SourceFiles" + "OutputProjectCanonicalName" = "8:Ivy\\Ivy.vcproj" + "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" + "ShowKeyOutput" = "11:TRUE" + "ExcludeFilters" + { + "ExcludeFilter" = "8:*.cpp" + } + } + "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_49CA588930534433BBD092FF33483A60" + { + "SourcePath" = "8:..\\InstIvy\\Debug\\InstIvy.msm" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_97BD9053CEE5430F9BC907C244C522C0" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:Built" + "OutputProjectCanonicalName" = "8:..\\..\\Install\\InstIvy\\InstIvy.vdproj" + "OutputProjectGuid" = "8:{E0749AC8-C631-4081-8E2D-02731D95BFDB}" + "ShowKeyOutput" = "11:TRUE" + "ExcludeFilters" + { + } + "KeyOutputModule" + { + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:..\\InstIvy\\Debug\\InstIvy.msm" + "ModuleSignature" = "8:MergeModule.50212549D8E242BBB1C9246BFDAFADB2" + "Properties" + { + "_7BEBD1D67A934D228BFBAE7C11467C9A.50212549D8E242BBB1C9246BFDAFADB2" + { + "Name" = "8:_7BEBD1D67A934D228BFBAE7C11467C9A.50212549D8E242BBB1C9246BFDAFADB2" + "DisplayName" = "8:Dossier Remplacement pour les modules" + "Description" = "8:" + "Type" = "3:32769" + "ContextData" = "8:_RetargetableFolder" + "Attributes" = "3:6" + "Setting" = "3:1" + "UsePlugInResources" = "11:FALSE" + } + } + "LanguageId" = "3:1036" + "Exclude" = "11:FALSE" + "Folder" = "8:_97BD9053CEE5430F9BC907C244C522C0" + "Feature" = "8:" + "IsolateTo" = "8:" + } + } + "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_93BB6066797941388D1B8E9C2D810A60" + { + "SourcePath" = "8:" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_64AFC2E36B5346C08FF007A580F68304" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:TRUE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:SourceFiles" + "OutputProjectCanonicalName" = "8:Ivy\\Ivy.vcproj" + "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" + "ShowKeyOutput" = "11:TRUE" + "ExcludeFilters" + { + "ExcludeFilter" = "8:*.cpp" + } + } + } + "Product" + { + "Name" = "8:Microsoft Visual Studio" + "ProductName" = "8:InstIvyDev" + "ProductCode" = "8:{54EEC85D-F868-49E0-A71C-54409C92E02F}" + "PackageCode" = "8:{49FE8C5C-E4B4-4BC9-B893-68E91BA65022}" + "UpgradeCode" = "8:{B61AA283-78E2-443D-A093-4D5D6C0B779A}" + "RestartWWWService" = "11:FALSE" + "RemovePreviousVersions" = "11:FALSE" + "DetectNewerInstalledVersion" = "11:TRUE" + "ProductVersion" = "8:1.0.0" + "Manufacturer" = "8:CENA" + "ARPHELPTELEPHONE" = "8:" + "ARPHELPLINK" = "8:" + "Title" = "8:InstIvyDev" + "Subject" = "8:" + "ARPCONTACT" = "8:CENA" + "Keywords" = "8:" + "ARPCOMMENTS" = "8:" + "ARPURLINFOABOUT" = "8:" + "ARPPRODUCTICON" = "8:" + "ARPIconIndex" = "3:0" + "SearchPath" = "8:" + "UseSystemSearchPath" = "11:TRUE" + } + "MsiBootstrapper" + { + "LangId" = "3:1036" + } + "MergeModule" + { + } + "UserInterface" + { + "{7DFFC192-4ABE-11D3-8D78-00A0C9CFCEE6}:_02EC527B9FF844D88C616726908FDF10" + { + "Name" = "8:#1902" + "Sequence" = "3:2" + "Attributes" = "3:3" + "Dialogs" + { + "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_BDEB1035C12E4BFEB8737D924C6F4156" + { + "Sequence" = "3:100" + "DisplayName" = "8:Terminé" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdAdminFinishedDlg.wid" + "ModuleSignature" = "8:VsdDialogs.83D22742_1B79_46f6_9A99_DF0F2BD4C077" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + } + } + "{E4ECAB26-4AB7-11D3-8D78-00A0C9CFCEE6}:_3750316B8DBF425BA6AA4348C0F1CA87" + { + "UseDynamicProperties" = "11:FALSE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdUserInterface.wim" + "ModuleSignature" = "8:VsdUserInterface.524F4245_5254_5341_4C45_534153783400" + } + "{7DFFC192-4ABE-11D3-8D78-00A0C9CFCEE6}:_51727C53A61B4F6D901F06AED9B3C481" + { + "Name" = "8:#1901" + "Sequence" = "3:1" + "Attributes" = "3:2" + "Dialogs" + { + "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_BA05984C1F294731B5ED66914BD89A5C" + { + "Sequence" = "3:100" + "DisplayName" = "8:Progression" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdProgressDlg.wid" + "ModuleSignature" = "8:VsdDialogs.4FB12620_0D15_42D0_8677_2766FFA6923F" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + "ShowProgress" + { + "Name" = "8:ShowProgress" + "DisplayName" = "8:#1009" + "Description" = "8:#1109" + "Type" = "3:5" + "ContextData" = "8:1;True=1;False=0" + "Attributes" = "3:0" + "Setting" = "3:0" + "Value" = "3:1" + "DefaultValue" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + } + } + "{7DFFC192-4ABE-11D3-8D78-00A0C9CFCEE6}:_6FF89DC49B8348899925787F1294FD64" + { + "Name" = "8:#1901" + "Sequence" = "3:2" + "Attributes" = "3:2" + "Dialogs" + { + "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_9F7D27549F654B418F380589DA56C3ED" + { + "Sequence" = "3:100" + "DisplayName" = "8:Progression" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdAdminProgressDlg.wid" + "ModuleSignature" = "8:VsdDialogs.EE9A1AFA_41DD_4514_B727_DF0ACA1D7389" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + "ShowProgress" + { + "Name" = "8:ShowProgress" + "DisplayName" = "8:#1009" + "Description" = "8:#1109" + "Type" = "3:5" + "ContextData" = "8:1;True=1;False=0" + "Attributes" = "3:0" + "Setting" = "3:0" + "Value" = "3:1" + "DefaultValue" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + } + } + "{7DFFC192-4ABE-11D3-8D78-00A0C9CFCEE6}:_8F8434AEBED14452982010E6F3848023" + { + "Name" = "8:#1900" + "Sequence" = "3:1" + "Attributes" = "3:1" + "Dialogs" + { + "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_97A4AE594BB347ECAD98AAFC6FD3B0FB" + { + "Sequence" = "3:200" + "DisplayName" = "8:Dossier d'installation" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdFolderDlg.wid" + "ModuleSignature" = "8:VsdDialogs.C113BC36_2532_4D45_8099_4818B1133B2F" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_E3B1F5B6B5FE4CE6B369C0374CA9AA75" + { + "Sequence" = "3:100" + "DisplayName" = "8:Bienvenue" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdWelcomeDlg.wid" + "ModuleSignature" = "8:VsdDialogs.68F69290_BB7C_474E_A153_6679845F3DDF" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + "CopyrightWarning" + { + "Name" = "8:CopyrightWarning" + "DisplayName" = "8:#1002" + "Description" = "8:#1102" + "Type" = "3:3" + "ContextData" = "8:" + "Attributes" = "3:0" + "Setting" = "3:1" + "Value" = "8:#1202" + "DefaultValue" = "8:#1202" + "UsePlugInResources" = "11:TRUE" + } + "Welcome" + { + "Name" = "8:Welcome" + "DisplayName" = "8:#1003" + "Description" = "8:#1103" + "Type" = "3:3" + "ContextData" = "8:" + "Attributes" = "3:0" + "Setting" = "3:1" + "Value" = "8:#1203" + "DefaultValue" = "8:#1203" + "UsePlugInResources" = "11:TRUE" + } + } + } + "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_EA128F65E9D44AE1B2E071C21B8C0010" + { + "Sequence" = "3:300" + "DisplayName" = "8:Confirmer l'installation" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdConfirmDlg.wid" + "ModuleSignature" = "8:VsdDialogs.6DBC9783_3677_4D68_8BF5_D749558A0AC1" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + } + } + "{E4ECAB26-4AB7-11D3-8D78-00A0C9CFCEE6}:_9AC53598B4544C15A28E2D88AD28D24E" + { + "UseDynamicProperties" = "11:FALSE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdBasicDialogs.wim" + "ModuleSignature" = "8:VsdDialogs.CE4B864F_F1C1_4B85_98D4_2A2BF5FFB12B" + } + "{7DFFC192-4ABE-11D3-8D78-00A0C9CFCEE6}:_D1645593CABE4CAF974F04BA8599A164" + { + "Name" = "8:#1900" + "Sequence" = "3:2" + "Attributes" = "3:1" + "Dialogs" + { + "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_0EE17FA1A76D4B8C86D0CA3BC7089F16" + { + "Sequence" = "3:100" + "DisplayName" = "8:Bienvenue" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdAdminWelcomeDlg.wid" + "ModuleSignature" = "8:VsdDialogs.E35A0E2C_F131_4B57_B946_59A1A2A8F45F" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + "CopyrightWarning" + { + "Name" = "8:CopyrightWarning" + "DisplayName" = "8:#1002" + "Description" = "8:#1102" + "Type" = "3:3" + "ContextData" = "8:" + "Attributes" = "3:0" + "Setting" = "3:1" + "Value" = "8:#1202" + "DefaultValue" = "8:#1202" + "UsePlugInResources" = "11:TRUE" + } + "Welcome" + { + "Name" = "8:Welcome" + "DisplayName" = "8:#1003" + "Description" = "8:#1103" + "Type" = "3:3" + "ContextData" = "8:" + "Attributes" = "3:0" + "Setting" = "3:1" + "Value" = "8:#1203" + "DefaultValue" = "8:#1203" + "UsePlugInResources" = "11:TRUE" + } + } + } + "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_B8FA44662FAF40B4A23F14BBE7115F3C" + { + "Sequence" = "3:300" + "DisplayName" = "8:Confirmer l'installation" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdAdminConfirmDlg.wid" + "ModuleSignature" = "8:VsdDialogs.FA58E60A_A1E8_4876_95FC_2AC3B5AAA5F8" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_F1C7DEE7DB5C4556ADD1217E3B254EC3" + { + "Sequence" = "3:200" + "DisplayName" = "8:Dossier d'installation" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdAdminFolderDlg.wid" + "ModuleSignature" = "8:VsdDialogs.2DED2424_5429_4616_A1AD_4D62837C2ADA" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + } + } + "{7DFFC192-4ABE-11D3-8D78-00A0C9CFCEE6}:_FED02DC05BEC48728F86FB64CF2C5B31" + { + "Name" = "8:#1902" + "Sequence" = "3:1" + "Attributes" = "3:3" + "Dialogs" + { + "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_83F73B2D8F7E44DA9567C4497FA978AB" + { + "Sequence" = "3:100" + "DisplayName" = "8:Terminé" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdFinishedDlg.wid" + "ModuleSignature" = "8:VsdDialogs.1DB77F5A_BA5C_4470_89B6_0B0EC07E3A10" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + } + } + } + } +} -- cgit v1.1 From 8fcf4068e42fa50ae3bdd371ee8e396e936b6241 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:54:59 +0000 Subject: Utilisateur : Fcolin Date : 5/11/02 Heure : 11:11 Archivé dans $/Bus/Install/InstIvyDev Commentaire: (vss 2) --- Ivy/InstIvyDev/InstIvyDev.vdproj | 63 +--------------------------------------- 1 file changed, 1 insertion(+), 62 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstIvyDev/InstIvyDev.vdproj b/Ivy/InstIvyDev/InstIvyDev.vdproj index 8b009f5..e7941e4 100644 --- a/Ivy/InstIvyDev/InstIvyDev.vdproj +++ b/Ivy/InstIvyDev/InstIvyDev.vdproj @@ -7,18 +7,12 @@ "LanguageId" = "3:1036" "CodePage" = "3:1252" "UILanguageId" = "3:1036" -"SccProjectName" = "8:\"$/Bus/InstIvyDev\", VQEAAAAA" +"SccProjectName" = "8:\"$/Bus/Install/InstIvyDev\", AREAAAAA" "SccLocalPath" = "8:." "SccAuxPath" = "8:" "SccProvider" = "8:MSSCCI:Microsoft Visual SourceSafe" "Hierarchy" { - "Entry" - { - "MsmKey" = "8:_49CA588930534433BBD092FF33483A60" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:MergeModule.50212549D8E242BBB1C9246BFDAFADB2" - } } "Configurations" { @@ -289,61 +283,6 @@ "ExcludeFilter" = "8:*.cpp" } } - "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_49CA588930534433BBD092FF33483A60" - { - "SourcePath" = "8:..\\InstIvy\\Debug\\InstIvy.msm" - "TargetName" = "8:" - "Tag" = "8:" - "Folder" = "8:_97BD9053CEE5430F9BC907C244C522C0" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - "ProjectOutputGroupRegister" = "3:1" - "OutputConfiguration" = "8:" - "OutputGroupCanonicalName" = "8:Built" - "OutputProjectCanonicalName" = "8:..\\..\\Install\\InstIvy\\InstIvy.vdproj" - "OutputProjectGuid" = "8:{E0749AC8-C631-4081-8E2D-02731D95BFDB}" - "ShowKeyOutput" = "11:TRUE" - "ExcludeFilters" - { - } - "KeyOutputModule" - { - "UseDynamicProperties" = "11:TRUE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:..\\InstIvy\\Debug\\InstIvy.msm" - "ModuleSignature" = "8:MergeModule.50212549D8E242BBB1C9246BFDAFADB2" - "Properties" - { - "_7BEBD1D67A934D228BFBAE7C11467C9A.50212549D8E242BBB1C9246BFDAFADB2" - { - "Name" = "8:_7BEBD1D67A934D228BFBAE7C11467C9A.50212549D8E242BBB1C9246BFDAFADB2" - "DisplayName" = "8:Dossier Remplacement pour les modules" - "Description" = "8:" - "Type" = "3:32769" - "ContextData" = "8:_RetargetableFolder" - "Attributes" = "3:6" - "Setting" = "3:1" - "UsePlugInResources" = "11:FALSE" - } - } - "LanguageId" = "3:1036" - "Exclude" = "11:FALSE" - "Folder" = "8:_97BD9053CEE5430F9BC907C244C522C0" - "Feature" = "8:" - "IsolateTo" = "8:" - } - } "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_93BB6066797941388D1B8E9C2D810A60" { "SourcePath" = "8:" -- cgit v1.1 From 5864ab3ce96fc326c2db2345582fb4499d13f2fc Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:01 +0000 Subject: Utilisateur : Fcolin Date : 6/01/05 Heure : 10:41 Archivé dans $/Bus/Ivy/InstIvyDev Commentaire: (vss 3) --- Ivy/InstIvyDev/InstIvyDev.vdproj | 440 ++++++++++++++++++++++++++------------- 1 file changed, 301 insertions(+), 139 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstIvyDev/InstIvyDev.vdproj b/Ivy/InstIvyDev/InstIvyDev.vdproj index e7941e4..ee4c4f3 100644 --- a/Ivy/InstIvyDev/InstIvyDev.vdproj +++ b/Ivy/InstIvyDev/InstIvyDev.vdproj @@ -1,18 +1,48 @@ "DeployProject" { -"VSVersion" = "3:700" -"ProjectType" = "8:{5443560c-dbb4-11d2-8724-00a0c9a8b90c}" +"VSVersion" = "3:701" +"ProjectType" = "8:{2C2AF0D9-9B47-4FE5-BEF2-169778172667}" "IsWebType" = "8:FALSE" -"ProjectName" = "8:InstIvyDev" +"ProjectName" = "8:InstallIvyDev" "LanguageId" = "3:1036" "CodePage" = "3:1252" "UILanguageId" = "3:1036" -"SccProjectName" = "8:\"$/Bus/Install/InstIvyDev\", AREAAAAA" +"SccProjectName" = "8:\"$/Bus/Ivy/InstIvyDev\", FUFAAAAA" "SccLocalPath" = "8:." "SccAuxPath" = "8:" "SccProvider" = "8:MSSCCI:Microsoft Visual SourceSafe" "Hierarchy" { + "Entry" + { + "MsmKey" = "8:_15EDC5AAD3B44A858CF9F20A9DDACE75" + "OwnerKey" = "8:_55FAFABEB2CF432DBC9AD1E024B8ABB0" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_2A4F621BFD46417A8CC4998092444420" + "OwnerKey" = "8:_UNDEFINED" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_38317E81A4F14F7595EC92880E6132D4" + "OwnerKey" = "8:_55FAFABEB2CF432DBC9AD1E024B8ABB0" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_55FAFABEB2CF432DBC9AD1E024B8ABB0" + "OwnerKey" = "8:_UNDEFINED" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_6FB50FA4D8F60743C6DAA4C31583C68C" + "OwnerKey" = "8:_55FAFABEB2CF432DBC9AD1E024B8ABB0" + "MsmSig" = "8:_UNDEFINED" + } } "Configurations" { @@ -46,7 +76,7 @@ "CertificateFile" = "8:" "PrivateKeyFile" = "8:" "TimeStampServer" = "8:" - "InstallerBootstrapper" = "3:2" + "InstallerBootstrapper" = "3:1" } } "Deployable" @@ -60,18 +90,64 @@ "Title" = "8:" "Description" = "8:" } + "ExternalPersistence" + { + "LaunchCondition" + { + } + } "Feature" { } "File" { + "{A582A373-4685-4296-BEFE-614B80A702C3}:_2A4F621BFD46417A8CC4998092444420" + { + "SourcePath" = "8:..\\Release\\Ivy.lib" + "TargetName" = "8:Ivy.lib" + "Tag" = "8:" + "Folder" = "8:_4BD06D3C92334052AE64EABA3DE642C3" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + } + "{A582A373-4685-4296-BEFE-614B80A702C3}:_6FB50FA4D8F60743C6DAA4C31583C68C" + { + "SourcePath" = "8:WSOCK32.dll" + "TargetName" = "8:WSOCK32.dll" + "Tag" = "8:" + "Folder" = "8:_97BD9053CEE5430F9BC907C244C522C0" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:TRUE" + "IsDependency" = "11:TRUE" + "IsolateTo" = "8:" + } } "FileType" { } "Folder" { - "{777C097F-0ED8-11D3-8D6C-00A0C9CFCEE6}:_4BD15901AAC84D5990E88963A8C59F03" + "{78BAF5CE-F2E5-45BE-83BC-DB6AF387E941}:_4BD15901AAC84D5990E88963A8C59F03" { "Name" = "8:#1919" "AlwaysCreate" = "11:FALSE" @@ -82,7 +158,7 @@ { } } - "{777C097F-0ED8-11D3-8D6C-00A0C9CFCEE6}:_6D7C73BF0915401FBCAE371A6B43BDC4" + "{78BAF5CE-F2E5-45BE-83BC-DB6AF387E941}:_6D7C73BF0915401FBCAE371A6B43BDC4" { "Name" = "8:#1916" "AlwaysCreate" = "11:FALSE" @@ -93,7 +169,7 @@ { } } - "{EE62640D-12F2-11D3-8D6C-00A0C9CFCEE6}:_97BD9053CEE5430F9BC907C244C522C0" + "{58C0ADA3-3CEA-43BD-A3B3-2EA121BC8217}:_97BD9053CEE5430F9BC907C244C522C0" { "DefaultLocation" = "8:[ProgramFilesFolder][Manufacturer]\\[ProductName]" "Name" = "8:#1925" @@ -103,7 +179,7 @@ "Property" = "8:TARGETDIR" "Folders" { - "{461E96AF-1495-11D3-8D6C-00A0C9CFCEE6}:_4BD06D3C92334052AE64EABA3DE642C3" + "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_4BD06D3C92334052AE64EABA3DE642C3" { "Name" = "8:Lib" "AlwaysCreate" = "11:FALSE" @@ -114,7 +190,7 @@ { } } - "{461E96AF-1495-11D3-8D6C-00A0C9CFCEE6}:_64AFC2E36B5346C08FF007A580F68304" + "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_64AFC2E36B5346C08FF007A580F68304" { "Name" = "8:Include" "AlwaysCreate" = "11:FALSE" @@ -125,7 +201,7 @@ { } } - "{461E96AF-1495-11D3-8D6C-00A0C9CFCEE6}:_823268F0927E471C9AC8D4518AB6C2F5" + "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_823268F0927E471C9AC8D4518AB6C2F5" { "Name" = "8:SrcExample" "AlwaysCreate" = "11:FALSE" @@ -136,7 +212,7 @@ { } } - "{461E96AF-1495-11D3-8D6C-00A0C9CFCEE6}:_9CFE50635C5443E68113471C7E3235C3" + "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_9CFE50635C5443E68113471C7E3235C3" { "Name" = "8:SrcLib" "AlwaysCreate" = "11:FALSE" @@ -156,11 +232,34 @@ "Locator" { } - "Shortcut" + "MsiBootstrapper" { + "LangId" = "3:1036" } - "Sequences" + "Product" { + "Name" = "8:Microsoft Visual Studio" + "ProductName" = "8:InstIvyDev" + "ProductCode" = "8:{54EEC85D-F868-49E0-A71C-54409C92E02F}" + "PackageCode" = "8:{D352AFFB-FC99-432F-90E6-CE2432E68692}" + "UpgradeCode" = "8:{B61AA283-78E2-443D-A093-4D5D6C0B779A}" + "RestartWWWService" = "11:FALSE" + "RemovePreviousVersions" = "11:FALSE" + "DetectNewerInstalledVersion" = "11:TRUE" + "ProductVersion" = "8:1.0.0" + "Manufacturer" = "8:CENA" + "ARPHELPTELEPHONE" = "8:" + "ARPHELPLINK" = "8:" + "Title" = "8:InstIvyDev" + "Subject" = "8:" + "ARPCONTACT" = "8:CENA" + "Keywords" = "8:" + "ARPCOMMENTS" = "8:" + "ARPURLINFOABOUT" = "8:" + "ARPPRODUCTICON" = "8:" + "ARPIconIndex" = "3:0" + "SearchPath" = "8:" + "UseSystemSearchPath" = "11:TRUE" } "Registry" { @@ -168,7 +267,7 @@ { "Keys" { - "{7DF0CD0A-FF27-11D2-8D6B-00A0C9CFCEE6}:_BB28EFBCAF6D427984A8D12ADA79ED71" + "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_BB28EFBCAF6D427984A8D12ADA79ED71" { "Name" = "8:Software" "Condition" = "8:" @@ -177,7 +276,7 @@ "Transitive" = "11:FALSE" "Keys" { - "{7DF0CD0A-FF27-11D2-8D6B-00A0C9CFCEE6}:_46BB5FEDD5E54B1DA83F1AEE69B7414D" + "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_46BB5FEDD5E54B1DA83F1AEE69B7414D" { "Name" = "8:[Manufacturer]" "Condition" = "8:" @@ -202,7 +301,7 @@ { "Keys" { - "{7DF0CD0A-FF27-11D2-8D6B-00A0C9CFCEE6}:_D254D89ED3C54FA68FAE6AD35F7725E3" + "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_D254D89ED3C54FA68FAE6AD35F7725E3" { "Name" = "8:Software" "Condition" = "8:" @@ -211,7 +310,7 @@ "Transitive" = "11:FALSE" "Keys" { - "{7DF0CD0A-FF27-11D2-8D6B-00A0C9CFCEE6}:_D96808EDD7E448E3BF4976DBB5153FDA" + "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_D96808EDD7E448E3BF4976DBB5153FDA" { "Name" = "8:[Manufacturer]" "Condition" = "8:" @@ -251,118 +350,28 @@ } } } - "ProjectOutput" - { - "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_3443BE23ACC842AB8885E291A36FEB88" - { - "SourcePath" = "8:" - "TargetName" = "8:" - "Tag" = "8:" - "Folder" = "8:_4BD06D3C92334052AE64EABA3DE642C3" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:TRUE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - "ProjectOutputGroupRegister" = "3:1" - "OutputConfiguration" = "8:" - "OutputGroupCanonicalName" = "8:SourceFiles" - "OutputProjectCanonicalName" = "8:Ivy\\Ivy.vcproj" - "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" - "ShowKeyOutput" = "11:TRUE" - "ExcludeFilters" - { - "ExcludeFilter" = "8:*.cpp" - } - } - "{B1E2BB22-187D-11D3-8E02-00C04F6837D0}:_93BB6066797941388D1B8E9C2D810A60" - { - "SourcePath" = "8:" - "TargetName" = "8:" - "Tag" = "8:" - "Folder" = "8:_64AFC2E36B5346C08FF007A580F68304" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:TRUE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - "ProjectOutputGroupRegister" = "3:1" - "OutputConfiguration" = "8:" - "OutputGroupCanonicalName" = "8:SourceFiles" - "OutputProjectCanonicalName" = "8:Ivy\\Ivy.vcproj" - "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" - "ShowKeyOutput" = "11:TRUE" - "ExcludeFilters" - { - "ExcludeFilter" = "8:*.cpp" - } - } - } - "Product" - { - "Name" = "8:Microsoft Visual Studio" - "ProductName" = "8:InstIvyDev" - "ProductCode" = "8:{54EEC85D-F868-49E0-A71C-54409C92E02F}" - "PackageCode" = "8:{49FE8C5C-E4B4-4BC9-B893-68E91BA65022}" - "UpgradeCode" = "8:{B61AA283-78E2-443D-A093-4D5D6C0B779A}" - "RestartWWWService" = "11:FALSE" - "RemovePreviousVersions" = "11:FALSE" - "DetectNewerInstalledVersion" = "11:TRUE" - "ProductVersion" = "8:1.0.0" - "Manufacturer" = "8:CENA" - "ARPHELPTELEPHONE" = "8:" - "ARPHELPLINK" = "8:" - "Title" = "8:InstIvyDev" - "Subject" = "8:" - "ARPCONTACT" = "8:CENA" - "Keywords" = "8:" - "ARPCOMMENTS" = "8:" - "ARPURLINFOABOUT" = "8:" - "ARPPRODUCTICON" = "8:" - "ARPIconIndex" = "3:0" - "SearchPath" = "8:" - "UseSystemSearchPath" = "11:TRUE" - } - "MsiBootstrapper" + "Sequences" { - "LangId" = "3:1036" } - "MergeModule" + "Shortcut" { } "UserInterface" { - "{7DFFC192-4ABE-11D3-8D78-00A0C9CFCEE6}:_02EC527B9FF844D88C616726908FDF10" + "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_02EC527B9FF844D88C616726908FDF10" { "Name" = "8:#1902" "Sequence" = "3:2" "Attributes" = "3:3" "Dialogs" { - "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_BDEB1035C12E4BFEB8737D924C6F4156" + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_BDEB1035C12E4BFEB8737D924C6F4156" { "Sequence" = "3:100" "DisplayName" = "8:Terminé" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminFinishedDlg.wid" - "ModuleSignature" = "8:VsdDialogs.83D22742_1B79_46f6_9A99_DF0F2BD4C077" "Properties" { "BannerBitmap" @@ -380,28 +389,26 @@ } } } - "{E4ECAB26-4AB7-11D3-8D78-00A0C9CFCEE6}:_3750316B8DBF425BA6AA4348C0F1CA87" + "{B654A020-6903-4E6A-A86C-75DC463DB54B}:_3750316B8DBF425BA6AA4348C0F1CA87" { "UseDynamicProperties" = "11:FALSE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdUserInterface.wim" - "ModuleSignature" = "8:VsdUserInterface.524F4245_5254_5341_4C45_534153783400" } - "{7DFFC192-4ABE-11D3-8D78-00A0C9CFCEE6}:_51727C53A61B4F6D901F06AED9B3C481" + "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_51727C53A61B4F6D901F06AED9B3C481" { "Name" = "8:#1901" "Sequence" = "3:1" "Attributes" = "3:2" "Dialogs" { - "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_BA05984C1F294731B5ED66914BD89A5C" + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_BA05984C1F294731B5ED66914BD89A5C" { "Sequence" = "3:100" "DisplayName" = "8:Progression" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdProgressDlg.wid" - "ModuleSignature" = "8:VsdDialogs.4FB12620_0D15_42D0_8677_2766FFA6923F" "Properties" { "BannerBitmap" @@ -432,21 +439,20 @@ } } } - "{7DFFC192-4ABE-11D3-8D78-00A0C9CFCEE6}:_6FF89DC49B8348899925787F1294FD64" + "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_6FF89DC49B8348899925787F1294FD64" { "Name" = "8:#1901" "Sequence" = "3:2" "Attributes" = "3:2" "Dialogs" { - "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_9F7D27549F654B418F380589DA56C3ED" + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_9F7D27549F654B418F380589DA56C3ED" { "Sequence" = "3:100" "DisplayName" = "8:Progression" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminProgressDlg.wid" - "ModuleSignature" = "8:VsdDialogs.EE9A1AFA_41DD_4514_B727_DF0ACA1D7389" "Properties" { "BannerBitmap" @@ -477,21 +483,20 @@ } } } - "{7DFFC192-4ABE-11D3-8D78-00A0C9CFCEE6}:_8F8434AEBED14452982010E6F3848023" + "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_8F8434AEBED14452982010E6F3848023" { "Name" = "8:#1900" "Sequence" = "3:1" "Attributes" = "3:1" "Dialogs" { - "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_97A4AE594BB347ECAD98AAFC6FD3B0FB" + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_97A4AE594BB347ECAD98AAFC6FD3B0FB" { "Sequence" = "3:200" "DisplayName" = "8:Dossier d'installation" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdFolderDlg.wid" - "ModuleSignature" = "8:VsdDialogs.C113BC36_2532_4D45_8099_4818B1133B2F" "Properties" { "BannerBitmap" @@ -507,14 +512,13 @@ } } } - "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_E3B1F5B6B5FE4CE6B369C0374CA9AA75" + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_E3B1F5B6B5FE4CE6B369C0374CA9AA75" { "Sequence" = "3:100" "DisplayName" = "8:Bienvenue" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdWelcomeDlg.wid" - "ModuleSignature" = "8:VsdDialogs.68F69290_BB7C_474E_A153_6679845F3DDF" "Properties" { "BannerBitmap" @@ -556,14 +560,13 @@ } } } - "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_EA128F65E9D44AE1B2E071C21B8C0010" + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_EA128F65E9D44AE1B2E071C21B8C0010" { "Sequence" = "3:300" "DisplayName" = "8:Confirmer l'installation" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdConfirmDlg.wid" - "ModuleSignature" = "8:VsdDialogs.6DBC9783_3677_4D68_8BF5_D749558A0AC1" "Properties" { "BannerBitmap" @@ -581,28 +584,26 @@ } } } - "{E4ECAB26-4AB7-11D3-8D78-00A0C9CFCEE6}:_9AC53598B4544C15A28E2D88AD28D24E" + "{B654A020-6903-4E6A-A86C-75DC463DB54B}:_9AC53598B4544C15A28E2D88AD28D24E" { "UseDynamicProperties" = "11:FALSE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdBasicDialogs.wim" - "ModuleSignature" = "8:VsdDialogs.CE4B864F_F1C1_4B85_98D4_2A2BF5FFB12B" } - "{7DFFC192-4ABE-11D3-8D78-00A0C9CFCEE6}:_D1645593CABE4CAF974F04BA8599A164" + "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_D1645593CABE4CAF974F04BA8599A164" { "Name" = "8:#1900" "Sequence" = "3:2" "Attributes" = "3:1" "Dialogs" { - "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_0EE17FA1A76D4B8C86D0CA3BC7089F16" + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_0EE17FA1A76D4B8C86D0CA3BC7089F16" { "Sequence" = "3:100" "DisplayName" = "8:Bienvenue" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminWelcomeDlg.wid" - "ModuleSignature" = "8:VsdDialogs.E35A0E2C_F131_4B57_B946_59A1A2A8F45F" "Properties" { "BannerBitmap" @@ -644,14 +645,13 @@ } } } - "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_B8FA44662FAF40B4A23F14BBE7115F3C" + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_B8FA44662FAF40B4A23F14BBE7115F3C" { "Sequence" = "3:300" "DisplayName" = "8:Confirmer l'installation" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminConfirmDlg.wid" - "ModuleSignature" = "8:VsdDialogs.FA58E60A_A1E8_4876_95FC_2AC3B5AAA5F8" "Properties" { "BannerBitmap" @@ -667,14 +667,13 @@ } } } - "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_F1C7DEE7DB5C4556ADD1217E3B254EC3" + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_F1C7DEE7DB5C4556ADD1217E3B254EC3" { "Sequence" = "3:200" "DisplayName" = "8:Dossier d'installation" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminFolderDlg.wid" - "ModuleSignature" = "8:VsdDialogs.2DED2424_5429_4616_A1AD_4D62837C2ADA" "Properties" { "BannerBitmap" @@ -692,21 +691,20 @@ } } } - "{7DFFC192-4ABE-11D3-8D78-00A0C9CFCEE6}:_FED02DC05BEC48728F86FB64CF2C5B31" + "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_FED02DC05BEC48728F86FB64CF2C5B31" { "Name" = "8:#1902" "Sequence" = "3:1" "Attributes" = "3:3" "Dialogs" { - "{E4ECAB24-4AB7-11D3-8D78-00A0C9CFCEE6}:_83F73B2D8F7E44DA9567C4497FA978AB" + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_83F73B2D8F7E44DA9567C4497FA978AB" { "Sequence" = "3:100" "DisplayName" = "8:Terminé" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdFinishedDlg.wid" - "ModuleSignature" = "8:VsdDialogs.1DB77F5A_BA5C_4470_89B6_0B0EC07E3A10" "Properties" { "BannerBitmap" @@ -720,10 +718,174 @@ "Setting" = "3:1" "UsePlugInResources" = "11:TRUE" } + "UpdateText" + { + "Name" = "8:UpdateText" + "DisplayName" = "8:#1058" + "Description" = "8:#1158" + "Type" = "3:15" + "ContextData" = "8:" + "Attributes" = "3:0" + "Setting" = "3:1" + "Value" = "8:#1258" + "DefaultValue" = "8:#1258" + "UsePlugInResources" = "11:TRUE" + } } } } } } + "MergeModule" + { + "{35A69C6E-5BA4-440D-803D-762B59A45393}:_15EDC5AAD3B44A858CF9F20A9DDACE75" + { + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:TRUE" + "SourcePath" = "8:vc_user_crt71_rtl_x86_---.msm" + "Properties" + { + } + "LanguageId" = "3:0" + "Exclude" = "11:FALSE" + "Folder" = "8:" + "Feature" = "8:" + "IsolateTo" = "8:" + } + "{35A69C6E-5BA4-440D-803D-762B59A45393}:_38317E81A4F14F7595EC92880E6132D4" + { + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:TRUE" + "SourcePath" = "8:vc_user_stl71_rtl_x86_---.msm" + "Properties" + { + } + "LanguageId" = "3:0" + "Exclude" = "11:FALSE" + "Folder" = "8:" + "Feature" = "8:" + "IsolateTo" = "8:" + } + } + "ProjectOutput" + { + "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_55FAFABEB2CF432DBC9AD1E024B8ABB0" + { + "SourcePath" = "8:..\\Release\\Ivy.dll" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_4BD06D3C92334052AE64EABA3DE642C3" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:Built" + "OutputProjectGuid" = "8:{84E0039A-6721-4B18-9792-E9AE4274AC0E}" + "ShowKeyOutput" = "11:TRUE" + "ExcludeFilters" + { + } + } + "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_B6AD60532F7C461DB33A87A938457122" + { + "SourcePath" = "8:" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_9CFE50635C5443E68113471C7E3235C3" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:SourceFiles" + "OutputProjectGuid" = "8:{84E0039A-6721-4B18-9792-E9AE4274AC0E}" + "ShowKeyOutput" = "11:TRUE" + "ExcludeFilters" + { + "ExcludeFilter" = "8:*.h" + } + } + "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_D846A39ABCA44B3C894FA624FD34ABA6" + { + "SourcePath" = "8:" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_64AFC2E36B5346C08FF007A580F68304" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:SourceFiles" + "OutputProjectGuid" = "8:{84E0039A-6721-4B18-9792-E9AE4274AC0E}" + "ShowKeyOutput" = "11:TRUE" + "ExcludeFilters" + { + "ExcludeFilter" = "8:*.cxx" + } + } + "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_D96261DD1EAA4C39B93D8C7259465C8D" + { + "SourcePath" = "8:" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_823268F0927E471C9AC8D4518AB6C2F5" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:SourceFiles" + "OutputProjectGuid" = "8:{B7F7F0F7-9029-4D1A-8CB4-C42DAF86A21C}" + "ShowKeyOutput" = "11:TRUE" + "ExcludeFilters" + { + } + } + } + "VJSharpPlugin" + { + } } } -- cgit v1.1 From 9654534678702c97cbdaed953c2b7b410852e90c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:03 +0000 Subject: Utilisateur : Fcolin Date : 20/01/06 Heure : 13:50 Archivé dans $/Bus/Ivy/InstIvyDev Commentaire: (vss 4) --- Ivy/InstIvyDev/InstIvyDev.vdproj | 255 ++++++++++++++++++++++----------------- 1 file changed, 143 insertions(+), 112 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstIvyDev/InstIvyDev.vdproj b/Ivy/InstIvyDev/InstIvyDev.vdproj index ee4c4f3..b3a6b0c 100644 --- a/Ivy/InstIvyDev/InstIvyDev.vdproj +++ b/Ivy/InstIvyDev/InstIvyDev.vdproj @@ -1,7 +1,7 @@ "DeployProject" { -"VSVersion" = "3:701" -"ProjectType" = "8:{2C2AF0D9-9B47-4FE5-BEF2-169778172667}" +"VSVersion" = "3:800" +"ProjectType" = "8:{978C614F-708E-4E1A-B201-565925725DBA}" "IsWebType" = "8:FALSE" "ProjectName" = "8:InstallIvyDev" "LanguageId" = "3:1036" @@ -15,32 +15,32 @@ { "Entry" { - "MsmKey" = "8:_15EDC5AAD3B44A858CF9F20A9DDACE75" - "OwnerKey" = "8:_55FAFABEB2CF432DBC9AD1E024B8ABB0" + "MsmKey" = "8:_62ED68A2D7494B03BD284E1F5A266D54" + "OwnerKey" = "8:_CC144D67864B484BB467E286722BA415" "MsmSig" = "8:_UNDEFINED" } "Entry" { - "MsmKey" = "8:_2A4F621BFD46417A8CC4998092444420" - "OwnerKey" = "8:_UNDEFINED" + "MsmKey" = "8:_6FB50FA4D8F60743C6DAA4C31583C68C" + "OwnerKey" = "8:_BFED66BE7DFC4FC5B625527D0526B5A5" "MsmSig" = "8:_UNDEFINED" } "Entry" { - "MsmKey" = "8:_38317E81A4F14F7595EC92880E6132D4" - "OwnerKey" = "8:_55FAFABEB2CF432DBC9AD1E024B8ABB0" + "MsmKey" = "8:_B656C8E7B4C5444BB7CAA2BB82B22DEB" + "OwnerKey" = "8:_UNDEFINED" "MsmSig" = "8:_UNDEFINED" } "Entry" { - "MsmKey" = "8:_55FAFABEB2CF432DBC9AD1E024B8ABB0" + "MsmKey" = "8:_BFED66BE7DFC4FC5B625527D0526B5A5" "OwnerKey" = "8:_UNDEFINED" "MsmSig" = "8:_UNDEFINED" } "Entry" { - "MsmKey" = "8:_6FB50FA4D8F60743C6DAA4C31583C68C" - "OwnerKey" = "8:_55FAFABEB2CF432DBC9AD1E024B8ABB0" + "MsmKey" = "8:_CC144D67864B484BB467E286722BA415" + "OwnerKey" = "8:_BFED66BE7DFC4FC5B625527D0526B5A5" "MsmSig" = "8:_UNDEFINED" } } @@ -61,13 +61,24 @@ "PrivateKeyFile" = "8:" "TimeStampServer" = "8:" "InstallerBootstrapper" = "3:1" + "BootstrapperCfg:{63ACBE69-63AA-4F98-B2B6-99F9E24495F2}" + { + "Enabled" = "11:FALSE" + "PromptEnabled" = "11:TRUE" + "PrerequisitesLocation" = "2:1" + "Url" = "8:" + "ComponentsUrl" = "8:" + "Items" + { + } + } } "Release" { "DisplayName" = "8:Release" "IsDebugOnly" = "11:FALSE" "IsReleaseOnly" = "11:TRUE" - "OutputFilename" = "8:Release\\InstIvyDev.msi" + "OutputFilename" = "8:..\\..\\..\\..\\Install\\InstIvyDev.msi" "PackageFilesAs" = "3:2" "PackageFileSize" = "3:-2147483648" "CabType" = "3:1" @@ -77,6 +88,17 @@ "PrivateKeyFile" = "8:" "TimeStampServer" = "8:" "InstallerBootstrapper" = "3:1" + "BootstrapperCfg:{63ACBE69-63AA-4F98-B2B6-99F9E24495F2}" + { + "Enabled" = "11:FALSE" + "PromptEnabled" = "11:TRUE" + "PrerequisitesLocation" = "2:1" + "Url" = "8:" + "ComponentsUrl" = "8:" + "Items" + { + } + } } } "Deployable" @@ -96,17 +118,14 @@ { } } - "Feature" - { - } "File" { - "{A582A373-4685-4296-BEFE-614B80A702C3}:_2A4F621BFD46417A8CC4998092444420" + "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_6FB50FA4D8F60743C6DAA4C31583C68C" { - "SourcePath" = "8:..\\Release\\Ivy.lib" - "TargetName" = "8:Ivy.lib" + "SourcePath" = "8:WSOCK32.dll" + "TargetName" = "8:WSOCK32.dll" "Tag" = "8:" - "Folder" = "8:_4BD06D3C92334052AE64EABA3DE642C3" + "Folder" = "8:_97BD9053CEE5430F9BC907C244C522C0" "Condition" = "8:" "Transitive" = "11:FALSE" "Vital" = "11:TRUE" @@ -118,15 +137,15 @@ "PackageAs" = "3:1" "Register" = "3:1" "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" + "IsDependency" = "11:TRUE" "IsolateTo" = "8:" } - "{A582A373-4685-4296-BEFE-614B80A702C3}:_6FB50FA4D8F60743C6DAA4C31583C68C" + "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_B656C8E7B4C5444BB7CAA2BB82B22DEB" { - "SourcePath" = "8:WSOCK32.dll" - "TargetName" = "8:WSOCK32.dll" + "SourcePath" = "8:..\\..\\release\\Ivy.lib" + "TargetName" = "8:Ivy.lib" "Tag" = "8:" - "Folder" = "8:_97BD9053CEE5430F9BC907C244C522C0" + "Folder" = "8:_4BD06D3C92334052AE64EABA3DE642C3" "Condition" = "8:" "Transitive" = "11:FALSE" "Vital" = "11:TRUE" @@ -137,8 +156,8 @@ "SharedLegacy" = "11:FALSE" "PackageAs" = "3:1" "Register" = "3:1" - "Exclude" = "11:TRUE" - "IsDependency" = "11:TRUE" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" "IsolateTo" = "8:" } } @@ -147,29 +166,7 @@ } "Folder" { - "{78BAF5CE-F2E5-45BE-83BC-DB6AF387E941}:_4BD15901AAC84D5990E88963A8C59F03" - { - "Name" = "8:#1919" - "AlwaysCreate" = "11:FALSE" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Property" = "8:ProgramMenuFolder" - "Folders" - { - } - } - "{78BAF5CE-F2E5-45BE-83BC-DB6AF387E941}:_6D7C73BF0915401FBCAE371A6B43BDC4" - { - "Name" = "8:#1916" - "AlwaysCreate" = "11:FALSE" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Property" = "8:DesktopFolder" - "Folders" - { - } - } - "{58C0ADA3-3CEA-43BD-A3B3-2EA121BC8217}:_97BD9053CEE5430F9BC907C244C522C0" + "{3C67513D-01DD-4637-8A68-80971EB9504F}:_97BD9053CEE5430F9BC907C244C522C0" { "DefaultLocation" = "8:[ProgramFilesFolder][Manufacturer]\\[ProductName]" "Name" = "8:#1925" @@ -179,7 +176,7 @@ "Property" = "8:TARGETDIR" "Folders" { - "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_4BD06D3C92334052AE64EABA3DE642C3" + "{9EF0B969-E518-4E46-987F-47570745A589}:_4BD06D3C92334052AE64EABA3DE642C3" { "Name" = "8:Lib" "AlwaysCreate" = "11:FALSE" @@ -190,7 +187,7 @@ { } } - "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_64AFC2E36B5346C08FF007A580F68304" + "{9EF0B969-E518-4E46-987F-47570745A589}:_64AFC2E36B5346C08FF007A580F68304" { "Name" = "8:Include" "AlwaysCreate" = "11:FALSE" @@ -201,7 +198,7 @@ { } } - "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_823268F0927E471C9AC8D4518AB6C2F5" + "{9EF0B969-E518-4E46-987F-47570745A589}:_823268F0927E471C9AC8D4518AB6C2F5" { "Name" = "8:SrcExample" "AlwaysCreate" = "11:FALSE" @@ -212,7 +209,7 @@ { } } - "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_9CFE50635C5443E68113471C7E3235C3" + "{9EF0B969-E518-4E46-987F-47570745A589}:_9CFE50635C5443E68113471C7E3235C3" { "Name" = "8:SrcLib" "AlwaysCreate" = "11:FALSE" @@ -223,6 +220,17 @@ { } } + "{9EF0B969-E518-4E46-987F-47570745A589}:_BE1B10BDB24D49EA8562F4B0A6596F21" + { + "Name" = "8:Bin" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:_4839FF1AF6C24020B0C868BA0C7D4D2E" + "Folders" + { + } + } } } } @@ -241,18 +249,19 @@ "Name" = "8:Microsoft Visual Studio" "ProductName" = "8:InstIvyDev" "ProductCode" = "8:{54EEC85D-F868-49E0-A71C-54409C92E02F}" - "PackageCode" = "8:{D352AFFB-FC99-432F-90E6-CE2432E68692}" + "PackageCode" = "8:{1FF4A935-F6B1-41D3-966D-41A851491448}" "UpgradeCode" = "8:{B61AA283-78E2-443D-A093-4D5D6C0B779A}" "RestartWWWService" = "11:FALSE" "RemovePreviousVersions" = "11:FALSE" "DetectNewerInstalledVersion" = "11:TRUE" + "InstallAllUsers" = "11:FALSE" "ProductVersion" = "8:1.0.0" - "Manufacturer" = "8:CENA" + "Manufacturer" = "8:SDER PII" "ARPHELPTELEPHONE" = "8:" "ARPHELPLINK" = "8:" "Title" = "8:InstIvyDev" "Subject" = "8:" - "ARPCONTACT" = "8:CENA" + "ARPCONTACT" = "8:SDER PII" "Keywords" = "8:" "ARPCOMMENTS" = "8:" "ARPURLINFOABOUT" = "8:" @@ -260,6 +269,10 @@ "ARPIconIndex" = "3:0" "SearchPath" = "8:" "UseSystemSearchPath" = "11:TRUE" + "TargetPlatform" = "3:0" + "PreBuildEvent" = "8:" + "PostBuildEvent" = "8:" + "RunPostBuildEvent" = "3:0" } "Registry" { @@ -267,7 +280,7 @@ { "Keys" { - "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_BB28EFBCAF6D427984A8D12ADA79ED71" + "{60EA8692-D2D5-43EB-80DC-7906BF13D6EF}:_BB28EFBCAF6D427984A8D12ADA79ED71" { "Name" = "8:Software" "Condition" = "8:" @@ -276,7 +289,7 @@ "Transitive" = "11:FALSE" "Keys" { - "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_46BB5FEDD5E54B1DA83F1AEE69B7414D" + "{60EA8692-D2D5-43EB-80DC-7906BF13D6EF}:_46BB5FEDD5E54B1DA83F1AEE69B7414D" { "Name" = "8:[Manufacturer]" "Condition" = "8:" @@ -301,7 +314,7 @@ { "Keys" { - "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_D254D89ED3C54FA68FAE6AD35F7725E3" + "{60EA8692-D2D5-43EB-80DC-7906BF13D6EF}:_D254D89ED3C54FA68FAE6AD35F7725E3" { "Name" = "8:Software" "Condition" = "8:" @@ -310,7 +323,7 @@ "Transitive" = "11:FALSE" "Keys" { - "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_D96808EDD7E448E3BF4976DBB5153FDA" + "{60EA8692-D2D5-43EB-80DC-7906BF13D6EF}:_D96808EDD7E448E3BF4976DBB5153FDA" { "Name" = "8:[Manufacturer]" "Condition" = "8:" @@ -358,17 +371,17 @@ } "UserInterface" { - "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_02EC527B9FF844D88C616726908FDF10" + "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_02EC527B9FF844D88C616726908FDF10" { "Name" = "8:#1902" "Sequence" = "3:2" "Attributes" = "3:3" "Dialogs" { - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_BDEB1035C12E4BFEB8737D924C6F4156" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_BDEB1035C12E4BFEB8737D924C6F4156" { "Sequence" = "3:100" - "DisplayName" = "8:Terminé" + "DisplayName" = "8:Finished" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminFinishedDlg.wid" @@ -389,23 +402,23 @@ } } } - "{B654A020-6903-4E6A-A86C-75DC463DB54B}:_3750316B8DBF425BA6AA4348C0F1CA87" + "{2479F3F5-0309-486D-8047-8187E2CE5BA0}:_3750316B8DBF425BA6AA4348C0F1CA87" { "UseDynamicProperties" = "11:FALSE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdUserInterface.wim" } - "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_51727C53A61B4F6D901F06AED9B3C481" + "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_51727C53A61B4F6D901F06AED9B3C481" { "Name" = "8:#1901" "Sequence" = "3:1" "Attributes" = "3:2" "Dialogs" { - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_BA05984C1F294731B5ED66914BD89A5C" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_BA05984C1F294731B5ED66914BD89A5C" { "Sequence" = "3:100" - "DisplayName" = "8:Progression" + "DisplayName" = "8:Progress" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdProgressDlg.wid" @@ -439,17 +452,17 @@ } } } - "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_6FF89DC49B8348899925787F1294FD64" + "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_6FF89DC49B8348899925787F1294FD64" { "Name" = "8:#1901" "Sequence" = "3:2" "Attributes" = "3:2" "Dialogs" { - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_9F7D27549F654B418F380589DA56C3ED" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_9F7D27549F654B418F380589DA56C3ED" { "Sequence" = "3:100" - "DisplayName" = "8:Progression" + "DisplayName" = "8:Progress" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminProgressDlg.wid" @@ -483,17 +496,17 @@ } } } - "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_8F8434AEBED14452982010E6F3848023" + "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_8F8434AEBED14452982010E6F3848023" { "Name" = "8:#1900" "Sequence" = "3:1" "Attributes" = "3:1" "Dialogs" { - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_97A4AE594BB347ECAD98AAFC6FD3B0FB" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_97A4AE594BB347ECAD98AAFC6FD3B0FB" { "Sequence" = "3:200" - "DisplayName" = "8:Dossier d'installation" + "DisplayName" = "8:Installation Folder" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdFolderDlg.wid" @@ -510,12 +523,25 @@ "Setting" = "3:1" "UsePlugInResources" = "11:TRUE" } + "InstallAllUsersVisible" + { + "Name" = "8:InstallAllUsersVisible" + "DisplayName" = "8:#1059" + "Description" = "8:#1159" + "Type" = "3:5" + "ContextData" = "8:1;True=1;False=0" + "Attributes" = "3:0" + "Setting" = "3:0" + "Value" = "3:1" + "DefaultValue" = "3:1" + "UsePlugInResources" = "11:TRUE" + } } } - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_E3B1F5B6B5FE4CE6B369C0374CA9AA75" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_E3B1F5B6B5FE4CE6B369C0374CA9AA75" { "Sequence" = "3:100" - "DisplayName" = "8:Bienvenue" + "DisplayName" = "8:Welcome" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdWelcomeDlg.wid" @@ -560,10 +586,10 @@ } } } - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_EA128F65E9D44AE1B2E071C21B8C0010" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_EA128F65E9D44AE1B2E071C21B8C0010" { "Sequence" = "3:300" - "DisplayName" = "8:Confirmer l'installation" + "DisplayName" = "8:Confirm Installation" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdConfirmDlg.wid" @@ -584,23 +610,23 @@ } } } - "{B654A020-6903-4E6A-A86C-75DC463DB54B}:_9AC53598B4544C15A28E2D88AD28D24E" + "{2479F3F5-0309-486D-8047-8187E2CE5BA0}:_9AC53598B4544C15A28E2D88AD28D24E" { "UseDynamicProperties" = "11:FALSE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdBasicDialogs.wim" } - "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_D1645593CABE4CAF974F04BA8599A164" + "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_D1645593CABE4CAF974F04BA8599A164" { "Name" = "8:#1900" "Sequence" = "3:2" "Attributes" = "3:1" "Dialogs" { - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_0EE17FA1A76D4B8C86D0CA3BC7089F16" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_0EE17FA1A76D4B8C86D0CA3BC7089F16" { "Sequence" = "3:100" - "DisplayName" = "8:Bienvenue" + "DisplayName" = "8:Welcome" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminWelcomeDlg.wid" @@ -645,10 +671,10 @@ } } } - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_B8FA44662FAF40B4A23F14BBE7115F3C" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_B8FA44662FAF40B4A23F14BBE7115F3C" { "Sequence" = "3:300" - "DisplayName" = "8:Confirmer l'installation" + "DisplayName" = "8:Confirm Installation" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminConfirmDlg.wid" @@ -667,10 +693,10 @@ } } } - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_F1C7DEE7DB5C4556ADD1217E3B254EC3" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_F1C7DEE7DB5C4556ADD1217E3B254EC3" { "Sequence" = "3:200" - "DisplayName" = "8:Dossier d'installation" + "DisplayName" = "8:Installation Folder" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminFolderDlg.wid" @@ -691,17 +717,17 @@ } } } - "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_FED02DC05BEC48728F86FB64CF2C5B31" + "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_FED02DC05BEC48728F86FB64CF2C5B31" { "Name" = "8:#1902" "Sequence" = "3:1" "Attributes" = "3:3" "Dialogs" { - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_83F73B2D8F7E44DA9567C4497FA978AB" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_83F73B2D8F7E44DA9567C4497FA978AB" { "Sequence" = "3:100" - "DisplayName" = "8:Terminé" + "DisplayName" = "8:Finished" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdFinishedDlg.wid" @@ -738,11 +764,11 @@ } "MergeModule" { - "{35A69C6E-5BA4-440D-803D-762B59A45393}:_15EDC5AAD3B44A858CF9F20A9DDACE75" + "{CEE29DC0-9FBA-4B99-8D47-5BC643D9B626}:_62ED68A2D7494B03BD284E1F5A266D54" { "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:TRUE" - "SourcePath" = "8:vc_user_crt71_rtl_x86_---.msm" + "SourcePath" = "8:policy_8_0_microsoft_vc80_crt_x86.msm" "Properties" { } @@ -752,11 +778,11 @@ "Feature" = "8:" "IsolateTo" = "8:" } - "{35A69C6E-5BA4-440D-803D-762B59A45393}:_38317E81A4F14F7595EC92880E6132D4" + "{CEE29DC0-9FBA-4B99-8D47-5BC643D9B626}:_CC144D67864B484BB467E286722BA415" { "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:TRUE" - "SourcePath" = "8:vc_user_stl71_rtl_x86_---.msm" + "SourcePath" = "8:Microsoft_VC80_CRT_x86.msm" "Properties" { } @@ -769,12 +795,12 @@ } "ProjectOutput" { - "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_55FAFABEB2CF432DBC9AD1E024B8ABB0" + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_0DBE25F652264D9F92A27A1581D093E3" { - "SourcePath" = "8:..\\Release\\Ivy.dll" + "SourcePath" = "8:" "TargetName" = "8:" "Tag" = "8:" - "Folder" = "8:_4BD06D3C92334052AE64EABA3DE642C3" + "Folder" = "8:_9CFE50635C5443E68113471C7E3235C3" "Condition" = "8:" "Transitive" = "11:FALSE" "Vital" = "11:TRUE" @@ -785,24 +811,27 @@ "SharedLegacy" = "11:FALSE" "PackageAs" = "3:1" "Register" = "3:1" - "Exclude" = "11:FALSE" + "Exclude" = "11:TRUE" "IsDependency" = "11:FALSE" "IsolateTo" = "8:" "ProjectOutputGroupRegister" = "3:1" "OutputConfiguration" = "8:" - "OutputGroupCanonicalName" = "8:Built" - "OutputProjectGuid" = "8:{84E0039A-6721-4B18-9792-E9AE4274AC0E}" + "OutputGroupCanonicalName" = "8:SourceFiles" + "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" "ShowKeyOutput" = "11:TRUE" "ExcludeFilters" { + "ExcludeFilter" = "8:*.vcproj" + "ExcludeFilter" = "8:*.res" + "ExcludeFilter" = "8:*.h" } } - "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_B6AD60532F7C461DB33A87A938457122" + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_10C831C856C745B8862A1DA57473BE41" { "SourcePath" = "8:" "TargetName" = "8:" "Tag" = "8:" - "Folder" = "8:_9CFE50635C5443E68113471C7E3235C3" + "Folder" = "8:_64AFC2E36B5346C08FF007A580F68304" "Condition" = "8:" "Transitive" = "11:FALSE" "Vital" = "11:TRUE" @@ -813,25 +842,28 @@ "SharedLegacy" = "11:FALSE" "PackageAs" = "3:1" "Register" = "3:1" - "Exclude" = "11:FALSE" + "Exclude" = "11:TRUE" "IsDependency" = "11:FALSE" "IsolateTo" = "8:" "ProjectOutputGroupRegister" = "3:1" "OutputConfiguration" = "8:" "OutputGroupCanonicalName" = "8:SourceFiles" - "OutputProjectGuid" = "8:{84E0039A-6721-4B18-9792-E9AE4274AC0E}" + "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" "ShowKeyOutput" = "11:TRUE" "ExcludeFilters" { - "ExcludeFilter" = "8:*.h" + "ExcludeFilter" = "8:*.vcproj" + "ExcludeFilter" = "8:*.cxx" + "ExcludeFilter" = "8:*.res" + "ExcludeFilter" = "8:*.cpp" } } - "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_D846A39ABCA44B3C894FA624FD34ABA6" + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_3EE353CD5A944D589E7FD68F71A9F409" { "SourcePath" = "8:" "TargetName" = "8:" "Tag" = "8:" - "Folder" = "8:_64AFC2E36B5346C08FF007A580F68304" + "Folder" = "8:_823268F0927E471C9AC8D4518AB6C2F5" "Condition" = "8:" "Transitive" = "11:FALSE" "Vital" = "11:TRUE" @@ -848,19 +880,18 @@ "ProjectOutputGroupRegister" = "3:1" "OutputConfiguration" = "8:" "OutputGroupCanonicalName" = "8:SourceFiles" - "OutputProjectGuid" = "8:{84E0039A-6721-4B18-9792-E9AE4274AC0E}" + "OutputProjectGuid" = "8:{B7F7F0F7-9029-4D1A-8CB4-C42DAF86A21C}" "ShowKeyOutput" = "11:TRUE" "ExcludeFilters" { - "ExcludeFilter" = "8:*.cxx" } } - "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_D96261DD1EAA4C39B93D8C7259465C8D" + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_BFED66BE7DFC4FC5B625527D0526B5A5" { - "SourcePath" = "8:" + "SourcePath" = "8:..\\..\\release\\Ivy.dll" "TargetName" = "8:" "Tag" = "8:" - "Folder" = "8:_823268F0927E471C9AC8D4518AB6C2F5" + "Folder" = "8:_97BD9053CEE5430F9BC907C244C522C0" "Condition" = "8:" "Transitive" = "11:FALSE" "Vital" = "11:TRUE" @@ -876,8 +907,8 @@ "IsolateTo" = "8:" "ProjectOutputGroupRegister" = "3:1" "OutputConfiguration" = "8:" - "OutputGroupCanonicalName" = "8:SourceFiles" - "OutputProjectGuid" = "8:{B7F7F0F7-9029-4D1A-8CB4-C42DAF86A21C}" + "OutputGroupCanonicalName" = "8:Built" + "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" "ShowKeyOutput" = "11:TRUE" "ExcludeFilters" { -- cgit v1.1 From ac6886461657bb1922c4129ccd1be52163a58799 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:05 +0000 Subject: Utilisateur : Fcolin Date : 28/03/06 Heure : 19:20 Archivé dans $/Bus/Ivy/InstIvyDev Commentaire: (vss 5) --- Ivy/InstIvyDev/InstIvyDev.vdproj | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstIvyDev/InstIvyDev.vdproj b/Ivy/InstIvyDev/InstIvyDev.vdproj index b3a6b0c..117485c 100644 --- a/Ivy/InstIvyDev/InstIvyDev.vdproj +++ b/Ivy/InstIvyDev/InstIvyDev.vdproj @@ -15,32 +15,32 @@ { "Entry" { - "MsmKey" = "8:_62ED68A2D7494B03BD284E1F5A266D54" - "OwnerKey" = "8:_CC144D67864B484BB467E286722BA415" + "MsmKey" = "8:_1318AC1979884CB68AFB933DF2E7E174" + "OwnerKey" = "8:_4A75722E127148B0B5A33B6FFB8DF746" "MsmSig" = "8:_UNDEFINED" } "Entry" { - "MsmKey" = "8:_6FB50FA4D8F60743C6DAA4C31583C68C" + "MsmKey" = "8:_4A75722E127148B0B5A33B6FFB8DF746" "OwnerKey" = "8:_BFED66BE7DFC4FC5B625527D0526B5A5" "MsmSig" = "8:_UNDEFINED" } "Entry" { - "MsmKey" = "8:_B656C8E7B4C5444BB7CAA2BB82B22DEB" - "OwnerKey" = "8:_UNDEFINED" + "MsmKey" = "8:_6FB50FA4D8F60743C6DAA4C31583C68C" + "OwnerKey" = "8:_BFED66BE7DFC4FC5B625527D0526B5A5" "MsmSig" = "8:_UNDEFINED" } "Entry" { - "MsmKey" = "8:_BFED66BE7DFC4FC5B625527D0526B5A5" + "MsmKey" = "8:_B656C8E7B4C5444BB7CAA2BB82B22DEB" "OwnerKey" = "8:_UNDEFINED" "MsmSig" = "8:_UNDEFINED" } "Entry" { - "MsmKey" = "8:_CC144D67864B484BB467E286722BA415" - "OwnerKey" = "8:_BFED66BE7DFC4FC5B625527D0526B5A5" + "MsmKey" = "8:_BFED66BE7DFC4FC5B625527D0526B5A5" + "OwnerKey" = "8:_UNDEFINED" "MsmSig" = "8:_UNDEFINED" } } @@ -136,7 +136,7 @@ "SharedLegacy" = "11:FALSE" "PackageAs" = "3:1" "Register" = "3:1" - "Exclude" = "11:FALSE" + "Exclude" = "11:TRUE" "IsDependency" = "11:TRUE" "IsolateTo" = "8:" } @@ -249,7 +249,7 @@ "Name" = "8:Microsoft Visual Studio" "ProductName" = "8:InstIvyDev" "ProductCode" = "8:{54EEC85D-F868-49E0-A71C-54409C92E02F}" - "PackageCode" = "8:{1FF4A935-F6B1-41D3-966D-41A851491448}" + "PackageCode" = "8:{B9640A4C-8E82-4371-8EE9-68F1C590D372}" "UpgradeCode" = "8:{B61AA283-78E2-443D-A093-4D5D6C0B779A}" "RestartWWWService" = "11:FALSE" "RemovePreviousVersions" = "11:FALSE" @@ -764,7 +764,7 @@ } "MergeModule" { - "{CEE29DC0-9FBA-4B99-8D47-5BC643D9B626}:_62ED68A2D7494B03BD284E1F5A266D54" + "{CEE29DC0-9FBA-4B99-8D47-5BC643D9B626}:_1318AC1979884CB68AFB933DF2E7E174" { "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:TRUE" @@ -778,7 +778,7 @@ "Feature" = "8:" "IsolateTo" = "8:" } - "{CEE29DC0-9FBA-4B99-8D47-5BC643D9B626}:_CC144D67864B484BB467E286722BA415" + "{CEE29DC0-9FBA-4B99-8D47-5BC643D9B626}:_4A75722E127148B0B5A33B6FFB8DF746" { "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:TRUE" @@ -811,7 +811,7 @@ "SharedLegacy" = "11:FALSE" "PackageAs" = "3:1" "Register" = "3:1" - "Exclude" = "11:TRUE" + "Exclude" = "11:FALSE" "IsDependency" = "11:FALSE" "IsolateTo" = "8:" "ProjectOutputGroupRegister" = "3:1" @@ -842,7 +842,7 @@ "SharedLegacy" = "11:FALSE" "PackageAs" = "3:1" "Register" = "3:1" - "Exclude" = "11:TRUE" + "Exclude" = "11:FALSE" "IsDependency" = "11:FALSE" "IsolateTo" = "8:" "ProjectOutputGroupRegister" = "3:1" -- cgit v1.1 From a7953e819530325c70b5bd86ea001d29a6ca62d5 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:07 +0000 Subject: Utilisateur : Fcolin Date : 1/08/06 Heure : 13:14 Archivé dans $/Bus/Ivy/InstIvyDev Commentaire: (vss 6) --- Ivy/InstIvyDev/InstIvyDev.vdproj | 148 +++++++++++++++++++++++++++++++++++---- 1 file changed, 134 insertions(+), 14 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstIvyDev/InstIvyDev.vdproj b/Ivy/InstIvyDev/InstIvyDev.vdproj index 117485c..25df386 100644 --- a/Ivy/InstIvyDev/InstIvyDev.vdproj +++ b/Ivy/InstIvyDev/InstIvyDev.vdproj @@ -15,14 +15,26 @@ { "Entry" { - "MsmKey" = "8:_1318AC1979884CB68AFB933DF2E7E174" - "OwnerKey" = "8:_4A75722E127148B0B5A33B6FFB8DF746" + "MsmKey" = "8:_0881ABF5280948D5AA93B02FECFC3956" + "OwnerKey" = "8:_587183B52DD64752997FFA522BC57D0A" "MsmSig" = "8:_UNDEFINED" } "Entry" { - "MsmKey" = "8:_4A75722E127148B0B5A33B6FFB8DF746" - "OwnerKey" = "8:_BFED66BE7DFC4FC5B625527D0526B5A5" + "MsmKey" = "8:_32C90C9C8FC242AE9C65DA1C92DA2700" + "OwnerKey" = "8:_UNDEFINED" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_587183B52DD64752997FFA522BC57D0A" + "OwnerKey" = "8:_UNDEFINED" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_6C5F1DCD58734C9D953B306F435ED006" + "OwnerKey" = "8:_7B9C5BFD7A8B4F36A616771B210FF5C8" "MsmSig" = "8:_UNDEFINED" } "Entry" @@ -33,6 +45,30 @@ } "Entry" { + "MsmKey" = "8:_7B9C5BFD7A8B4F36A616771B210FF5C8" + "OwnerKey" = "8:_32C90C9C8FC242AE9C65DA1C92DA2700" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_7B9C5BFD7A8B4F36A616771B210FF5C8" + "OwnerKey" = "8:_BFED66BE7DFC4FC5B625527D0526B5A5" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_7B9C5BFD7A8B4F36A616771B210FF5C8" + "OwnerKey" = "8:_587183B52DD64752997FFA522BC57D0A" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_AB55CBB0776C4E9E90F5CB636E7D660B" + "OwnerKey" = "8:_0881ABF5280948D5AA93B02FECFC3956" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { "MsmKey" = "8:_B656C8E7B4C5444BB7CAA2BB82B22DEB" "OwnerKey" = "8:_UNDEFINED" "MsmSig" = "8:_UNDEFINED" @@ -93,7 +129,7 @@ "Enabled" = "11:FALSE" "PromptEnabled" = "11:TRUE" "PrerequisitesLocation" = "2:1" - "Url" = "8:" + "Url" = "8:http://www.tls.cena.fr/products/ivy/download/packages" "ComponentsUrl" = "8:" "Items" { @@ -249,7 +285,7 @@ "Name" = "8:Microsoft Visual Studio" "ProductName" = "8:InstIvyDev" "ProductCode" = "8:{54EEC85D-F868-49E0-A71C-54409C92E02F}" - "PackageCode" = "8:{B9640A4C-8E82-4371-8EE9-68F1C590D372}" + "PackageCode" = "8:{4A4A8B44-7D84-4AEB-98DA-766B603AD502}" "UpgradeCode" = "8:{B61AA283-78E2-443D-A093-4D5D6C0B779A}" "RestartWWWService" = "11:FALSE" "RemovePreviousVersions" = "11:FALSE" @@ -258,12 +294,12 @@ "ProductVersion" = "8:1.0.0" "Manufacturer" = "8:SDER PII" "ARPHELPTELEPHONE" = "8:" - "ARPHELPLINK" = "8:" + "ARPHELPLINK" = "8:http://www.tls.cena.fr/products/ivy" "Title" = "8:InstIvyDev" - "Subject" = "8:" + "Subject" = "8:Ivy" "ARPCONTACT" = "8:SDER PII" - "Keywords" = "8:" - "ARPCOMMENTS" = "8:" + "Keywords" = "8:Ivy" + "ARPCOMMENTS" = "8:Ivy Sources and Lib " "ARPURLINFOABOUT" = "8:" "ARPPRODUCTICON" = "8:" "ARPIconIndex" = "3:0" @@ -271,7 +307,7 @@ "UseSystemSearchPath" = "11:TRUE" "TargetPlatform" = "3:0" "PreBuildEvent" = "8:" - "PostBuildEvent" = "8:" + "PostBuildEvent" = "8:\"$(ProjectDir)..\\..\\UpdateIvyWeb.bat\" \"$(BuiltOuputPath)\"" "RunPostBuildEvent" = "3:0" } "Registry" @@ -764,7 +800,21 @@ } "MergeModule" { - "{CEE29DC0-9FBA-4B99-8D47-5BC643D9B626}:_1318AC1979884CB68AFB933DF2E7E174" + "{CEE29DC0-9FBA-4B99-8D47-5BC643D9B626}:_0881ABF5280948D5AA93B02FECFC3956" + { + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:TRUE" + "SourcePath" = "8:Microsoft_VC80_MFC_x86.msm" + "Properties" + { + } + "LanguageId" = "3:0" + "Exclude" = "11:FALSE" + "Folder" = "8:" + "Feature" = "8:" + "IsolateTo" = "8:" + } + "{CEE29DC0-9FBA-4B99-8D47-5BC643D9B626}:_6C5F1DCD58734C9D953B306F435ED006" { "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:TRUE" @@ -778,7 +828,7 @@ "Feature" = "8:" "IsolateTo" = "8:" } - "{CEE29DC0-9FBA-4B99-8D47-5BC643D9B626}:_4A75722E127148B0B5A33B6FFB8DF746" + "{CEE29DC0-9FBA-4B99-8D47-5BC643D9B626}:_7B9C5BFD7A8B4F36A616771B210FF5C8" { "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:TRUE" @@ -792,6 +842,20 @@ "Feature" = "8:" "IsolateTo" = "8:" } + "{CEE29DC0-9FBA-4B99-8D47-5BC643D9B626}:_AB55CBB0776C4E9E90F5CB636E7D660B" + { + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:TRUE" + "SourcePath" = "8:policy_8_0_microsoft_vc80_mfc_x86.msm" + "Properties" + { + } + "LanguageId" = "3:0" + "Exclude" = "11:FALSE" + "Folder" = "8:" + "Feature" = "8:" + "IsolateTo" = "8:" + } } "ProjectOutput" { @@ -858,6 +922,34 @@ "ExcludeFilter" = "8:*.cpp" } } + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_32C90C9C8FC242AE9C65DA1C92DA2700" + { + "SourcePath" = "8:..\\..\\release\\pcre.dll" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_BE1B10BDB24D49EA8562F4B0A6596F21" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:Built" + "OutputProjectGuid" = "8:{D79FC143-498E-4342-B2C7-BDAD1B8D0E6B}" + "ShowKeyOutput" = "11:TRUE" + "ExcludeFilters" + { + } + } "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_3EE353CD5A944D589E7FD68F71A9F409" { "SourcePath" = "8:" @@ -886,12 +978,40 @@ { } } + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_587183B52DD64752997FFA522BC57D0A" + { + "SourcePath" = "8:c:\\users\\fcolin\\program files\\release\\IvyProbe.exe" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_BE1B10BDB24D49EA8562F4B0A6596F21" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:Built" + "OutputProjectGuid" = "8:{B7F7F0F7-9029-4D1A-8CB4-C42DAF86A21C}" + "ShowKeyOutput" = "11:TRUE" + "ExcludeFilters" + { + } + } "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_BFED66BE7DFC4FC5B625527D0526B5A5" { "SourcePath" = "8:..\\..\\release\\Ivy.dll" "TargetName" = "8:" "Tag" = "8:" - "Folder" = "8:_97BD9053CEE5430F9BC907C244C522C0" + "Folder" = "8:_BE1B10BDB24D49EA8562F4B0A6596F21" "Condition" = "8:" "Transitive" = "11:FALSE" "Vital" = "11:TRUE" -- cgit v1.1 From 06ebad0af57ba0f5efabc4932c6af6e332f2a7f0 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:09 +0000 Subject: Utilisateur : Fcolin Date : 3/10/02 Heure : 12:09 Créé Commentaire: (vss 1) --- Ivy/InstIvyDev/InstIvyDev.vdproj.vspscc | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 Ivy/InstIvyDev/InstIvyDev.vdproj.vspscc (limited to 'Ivy') diff --git a/Ivy/InstIvyDev/InstIvyDev.vdproj.vspscc b/Ivy/InstIvyDev/InstIvyDev.vdproj.vspscc new file mode 100644 index 0000000..587f3d9 --- /dev/null +++ b/Ivy/InstIvyDev/InstIvyDev.vdproj.vspscc @@ -0,0 +1,10 @@ +"" +{ +"FILE_VERSION" = "9237" +"ENLISTMENT_CHOICE" = "NEVER" +"PROJECT_FILE_RELATIVE_PATH" = "" +"NUMBER_OF_EXCLUDED_FILES" = "0" +"ORIGINAL_PROJECT_FILE_PATH" = "" +"NUMBER_OF_NESTED_PROJECTS" = "0" +"SOURCE_CONTROL_SETTINGS_PROVIDER" = "PROJECT" +} -- cgit v1.1 From 1df6fa4f6c1fe0a2e6119c0de63c1ba954764984 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:17 +0000 Subject: Utilisateur : Fcolin Date : 4/01/05 Heure : 14:48 Créé Commentaire: (vss 1) --- Ivy/InstallSource/InstallSource.vdproj | 752 +++++++++++++++++++++++++++++++++ 1 file changed, 752 insertions(+) create mode 100644 Ivy/InstallSource/InstallSource.vdproj (limited to 'Ivy') diff --git a/Ivy/InstallSource/InstallSource.vdproj b/Ivy/InstallSource/InstallSource.vdproj new file mode 100644 index 0000000..ae6624f --- /dev/null +++ b/Ivy/InstallSource/InstallSource.vdproj @@ -0,0 +1,752 @@ +"DeployProject" +{ +"VSVersion" = "3:701" +"ProjectType" = "8:{2C2AF0D9-9B47-4FE5-BEF2-169778172667}" +"IsWebType" = "8:FALSE" +"ProjectName" = "8:InstallSource" +"LanguageId" = "3:1036" +"CodePage" = "3:1252" +"UILanguageId" = "3:1036" +"SccProjectName" = "8:SAK" +"SccLocalPath" = "8:SAK" +"SccAuxPath" = "8:SAK" +"SccProvider" = "8:SAK" + "Hierarchy" + { + } + "Configurations" + { + "Debug" + { + "DisplayName" = "8:Debug" + "IsDebugOnly" = "11:TRUE" + "IsReleaseOnly" = "11:FALSE" + "OutputFilename" = "8:Debug\\InstallSource.msi" + "PackageFilesAs" = "3:2" + "PackageFileSize" = "3:-2147483648" + "CabType" = "3:1" + "Compression" = "3:2" + "SignOutput" = "11:FALSE" + "CertificateFile" = "8:" + "PrivateKeyFile" = "8:" + "TimeStampServer" = "8:" + "InstallerBootstrapper" = "3:2" + } + "Release" + { + "DisplayName" = "8:Release" + "IsDebugOnly" = "11:FALSE" + "IsReleaseOnly" = "11:TRUE" + "OutputFilename" = "8:Release\\InstallSource.msi" + "PackageFilesAs" = "3:2" + "PackageFileSize" = "3:-2147483648" + "CabType" = "3:1" + "Compression" = "3:2" + "SignOutput" = "11:FALSE" + "CertificateFile" = "8:" + "PrivateKeyFile" = "8:" + "TimeStampServer" = "8:" + "InstallerBootstrapper" = "3:2" + } + } + "Deployable" + { + "CustomAction" + { + } + "DefaultFeature" + { + "Name" = "8:DefaultFeature" + "Title" = "8:" + "Description" = "8:" + } + "ExternalPersistence" + { + "LaunchCondition" + { + } + } + "Feature" + { + } + "File" + { + } + "FileType" + { + } + "Folder" + { + "{78BAF5CE-F2E5-45BE-83BC-DB6AF387E941}:_34A3F2CD942D42DBBF33B8154F9BE594" + { + "Name" = "8:#1916" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:DesktopFolder" + "Folders" + { + } + } + "{78BAF5CE-F2E5-45BE-83BC-DB6AF387E941}:_9A19D5AD4187451890787BE5AAD5D8A2" + { + "Name" = "8:#1919" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:ProgramMenuFolder" + "Folders" + { + } + } + "{58C0ADA3-3CEA-43BD-A3B3-2EA121BC8217}:_B3B7EB8E946F45E1BA06E9D854393106" + { + "DefaultLocation" = "8:[ProgramFilesFolder][Manufacturer]\\[ProductName]" + "Name" = "8:#1925" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:TARGETDIR" + "Folders" + { + "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_09678DC790BE461A87B4C5BE4A24046B" + { + "Name" = "8:comIvy" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:_33B5EB2D56D7495C87248919CACD5442" + "Folders" + { + } + } + "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_982736CE041D479585A839B95041A4C3" + { + "Name" = "8:Ivy" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:_E96D066878304D268825DFE0DDE10D44" + "Folders" + { + } + } + "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_D5ABE290941D4E11A32C1B4224453B50" + { + "Name" = "8:IvyProbe" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Property" = "8:_D6C5E160784140D3B122D7535BF25441" + "Folders" + { + } + } + } + } + } + "LaunchCondition" + { + } + "Locator" + { + } + "MsiBootstrapper" + { + "LangId" = "3:1036" + } + "Product" + { + "Name" = "8:Microsoft Visual Studio" + "ProductName" = "8:InstallSource" + "ProductCode" = "8:{9C865A50-9302-4B25-B699-88A034620AEA}" + "PackageCode" = "8:{0E024615-C205-43BC-9494-F7E780B27CBB}" + "UpgradeCode" = "8:{779E9266-AC8C-490F-8519-7B26BDA9E0F3}" + "RestartWWWService" = "11:FALSE" + "RemovePreviousVersions" = "11:FALSE" + "DetectNewerInstalledVersion" = "11:TRUE" + "ProductVersion" = "8:1.0.0" + "Manufacturer" = "8:Nom de société par défaut" + "ARPHELPTELEPHONE" = "8:" + "ARPHELPLINK" = "8:" + "Title" = "8:InstallSource" + "Subject" = "8:" + "ARPCONTACT" = "8:Nom de société par défaut" + "Keywords" = "8:" + "ARPCOMMENTS" = "8:" + "ARPURLINFOABOUT" = "8:" + "ARPPRODUCTICON" = "8:" + "ARPIconIndex" = "3:0" + "SearchPath" = "8:" + "UseSystemSearchPath" = "11:TRUE" + } + "Registry" + { + "HKLM" + { + "Keys" + { + "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_53933E3AD9234F12A4873FFA9773F31B" + { + "Name" = "8:Software" + "Condition" = "8:" + "AlwaysCreate" = "11:FALSE" + "DeleteAtUninstall" = "11:FALSE" + "Transitive" = "11:FALSE" + "Keys" + { + "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_7A4AE5DE0CDC412DB0987B541DAEEA5C" + { + "Name" = "8:[Manufacturer]" + "Condition" = "8:" + "AlwaysCreate" = "11:FALSE" + "DeleteAtUninstall" = "11:FALSE" + "Transitive" = "11:FALSE" + "Keys" + { + } + "Values" + { + } + } + } + "Values" + { + } + } + } + } + "HKCU" + { + "Keys" + { + "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_44F3154318AA4F4E8261D87380278D24" + { + "Name" = "8:Software" + "Condition" = "8:" + "AlwaysCreate" = "11:FALSE" + "DeleteAtUninstall" = "11:FALSE" + "Transitive" = "11:FALSE" + "Keys" + { + "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_9E06D03F3A794C62A13E46DD90ECF5C2" + { + "Name" = "8:[Manufacturer]" + "Condition" = "8:" + "AlwaysCreate" = "11:FALSE" + "DeleteAtUninstall" = "11:FALSE" + "Transitive" = "11:FALSE" + "Keys" + { + } + "Values" + { + } + } + } + "Values" + { + } + } + } + } + "HKCR" + { + "Keys" + { + } + } + "HKU" + { + "Keys" + { + } + } + "HKPU" + { + "Keys" + { + } + } + } + "Sequences" + { + } + "Shortcut" + { + } + "UserInterface" + { + "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_0A813400DCAA4CA2AED300FE90057CD5" + { + "Name" = "8:#1902" + "Sequence" = "3:1" + "Attributes" = "3:3" + "Dialogs" + { + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_D10C5ED5EBA44D81A8E5ABCD373D3DFB" + { + "Sequence" = "3:100" + "DisplayName" = "8:Terminé" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdFinishedDlg.wid" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + "UpdateText" + { + "Name" = "8:UpdateText" + "DisplayName" = "8:#1058" + "Description" = "8:#1158" + "Type" = "3:15" + "ContextData" = "8:" + "Attributes" = "3:0" + "Setting" = "3:1" + "Value" = "8:#1258" + "DefaultValue" = "8:#1258" + "UsePlugInResources" = "11:TRUE" + } + } + } + } + } + "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_0BBD850026394B248C77CF0D6A143DCC" + { + "Name" = "8:#1901" + "Sequence" = "3:2" + "Attributes" = "3:2" + "Dialogs" + { + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_C6C426B741844BD2B3CEDB5637FA9398" + { + "Sequence" = "3:100" + "DisplayName" = "8:Progression" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdAdminProgressDlg.wid" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + "ShowProgress" + { + "Name" = "8:ShowProgress" + "DisplayName" = "8:#1009" + "Description" = "8:#1109" + "Type" = "3:5" + "ContextData" = "8:1;True=1;False=0" + "Attributes" = "3:0" + "Setting" = "3:0" + "Value" = "3:1" + "DefaultValue" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + } + } + "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_138810673D2A4B039E304596343A481D" + { + "Name" = "8:#1902" + "Sequence" = "3:2" + "Attributes" = "3:3" + "Dialogs" + { + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_F70B3043BFCB4E2CAE3E5D5165AEF3BE" + { + "Sequence" = "3:100" + "DisplayName" = "8:Terminé" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdAdminFinishedDlg.wid" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + } + } + "{B654A020-6903-4E6A-A86C-75DC463DB54B}:_14D0F4EA9F4542A9A7180215B5B185E0" + { + "UseDynamicProperties" = "11:FALSE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdBasicDialogs.wim" + } + "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_A5F428FF10E64C82A99936F0EEFE6C9A" + { + "Name" = "8:#1900" + "Sequence" = "3:1" + "Attributes" = "3:1" + "Dialogs" + { + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_BC6CF4D097A54F8796A6DC0991F61A8A" + { + "Sequence" = "3:300" + "DisplayName" = "8:Confirmer l'installation" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdConfirmDlg.wid" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_C59FDD5750904CE69714920B25A7A1D5" + { + "Sequence" = "3:200" + "DisplayName" = "8:Dossier d'installation" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdFolderDlg.wid" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_F3608A2FED224610A31E8BA94D72172B" + { + "Sequence" = "3:100" + "DisplayName" = "8:Bienvenue" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdWelcomeDlg.wid" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + "CopyrightWarning" + { + "Name" = "8:CopyrightWarning" + "DisplayName" = "8:#1002" + "Description" = "8:#1102" + "Type" = "3:3" + "ContextData" = "8:" + "Attributes" = "3:0" + "Setting" = "3:1" + "Value" = "8:#1202" + "DefaultValue" = "8:#1202" + "UsePlugInResources" = "11:TRUE" + } + "Welcome" + { + "Name" = "8:Welcome" + "DisplayName" = "8:#1003" + "Description" = "8:#1103" + "Type" = "3:3" + "ContextData" = "8:" + "Attributes" = "3:0" + "Setting" = "3:1" + "Value" = "8:#1203" + "DefaultValue" = "8:#1203" + "UsePlugInResources" = "11:TRUE" + } + } + } + } + } + "{B654A020-6903-4E6A-A86C-75DC463DB54B}:_B959F1B9EF674DF1AAAC84393D11F1F4" + { + "UseDynamicProperties" = "11:FALSE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdUserInterface.wim" + } + "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_BF96EE5647E446EE8E09C7161F2D15C6" + { + "Name" = "8:#1900" + "Sequence" = "3:2" + "Attributes" = "3:1" + "Dialogs" + { + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_5DD5731B72974577BB1FE53249896CE6" + { + "Sequence" = "3:300" + "DisplayName" = "8:Confirmer l'installation" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdAdminConfirmDlg.wid" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_6CF0FA0D246440D18CF8219B20779B9B" + { + "Sequence" = "3:200" + "DisplayName" = "8:Dossier d'installation" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdAdminFolderDlg.wid" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_7232E533C8364A2481A6BF178EF00E6E" + { + "Sequence" = "3:100" + "DisplayName" = "8:Bienvenue" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdAdminWelcomeDlg.wid" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + "CopyrightWarning" + { + "Name" = "8:CopyrightWarning" + "DisplayName" = "8:#1002" + "Description" = "8:#1102" + "Type" = "3:3" + "ContextData" = "8:" + "Attributes" = "3:0" + "Setting" = "3:1" + "Value" = "8:#1202" + "DefaultValue" = "8:#1202" + "UsePlugInResources" = "11:TRUE" + } + "Welcome" + { + "Name" = "8:Welcome" + "DisplayName" = "8:#1003" + "Description" = "8:#1103" + "Type" = "3:3" + "ContextData" = "8:" + "Attributes" = "3:0" + "Setting" = "3:1" + "Value" = "8:#1203" + "DefaultValue" = "8:#1203" + "UsePlugInResources" = "11:TRUE" + } + } + } + } + } + "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_D683AF1F16134222A207B5C3D986AFD7" + { + "Name" = "8:#1901" + "Sequence" = "3:1" + "Attributes" = "3:2" + "Dialogs" + { + "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_6A78AB4A47D846BE8BCFE2FD4B21FED4" + { + "Sequence" = "3:100" + "DisplayName" = "8:Progression" + "UseDynamicProperties" = "11:TRUE" + "IsDependency" = "11:FALSE" + "SourcePath" = "8:\\VsdProgressDlg.wid" + "Properties" + { + "BannerBitmap" + { + "Name" = "8:BannerBitmap" + "DisplayName" = "8:#1001" + "Description" = "8:#1101" + "Type" = "3:8" + "ContextData" = "8:Bitmap" + "Attributes" = "3:4" + "Setting" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + "ShowProgress" + { + "Name" = "8:ShowProgress" + "DisplayName" = "8:#1009" + "Description" = "8:#1109" + "Type" = "3:5" + "ContextData" = "8:1;True=1;False=0" + "Attributes" = "3:0" + "Setting" = "3:0" + "Value" = "3:1" + "DefaultValue" = "3:1" + "UsePlugInResources" = "11:TRUE" + } + } + } + } + } + } + "MergeModule" + { + } + "ProjectOutput" + { + "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_31B0D0C4AA7F433F8B505436C2D1D325" + { + "SourcePath" = "8:" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_D5ABE290941D4E11A32C1B4224453B50" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:SourceFiles" + "OutputProjectGuid" = "8:{B7F7F0F7-9029-4D1A-8CB4-C42DAF86A21C}" + "ShowKeyOutput" = "11:TRUE" + "ExcludeFilters" + { + } + } + "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_4BDAFC134AA14038BB9F9243DCCD5FFD" + { + "SourcePath" = "8:" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_09678DC790BE461A87B4C5BE4A24046B" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:SourceFiles" + "OutputProjectGuid" = "8:{561E32B8-AF2E-4BA4-8D1D-159CC71E2C90}" + "ShowKeyOutput" = "11:TRUE" + "ExcludeFilters" + { + } + } + "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_82D4223AEA774E18932622E6A2FF85ED" + { + "SourcePath" = "8:" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_982736CE041D479585A839B95041A4C3" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:SourceFiles" + "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" + "ShowKeyOutput" = "11:TRUE" + "ExcludeFilters" + { + } + } + } + "VJSharpPlugin" + { + } + } +} -- cgit v1.1 From 9d47219ac905f9b43c72e777e37e70db90581df6 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:18 +0000 Subject: Utilisateur : Fcolin Date : 4/01/05 Heure : 17:04 Archivé dans $/Bus/Ivy/InstallSource Commentaire: (vss 2) --- Ivy/InstallSource/InstallSource.vdproj | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstallSource/InstallSource.vdproj b/Ivy/InstallSource/InstallSource.vdproj index ae6624f..24d4533 100644 --- a/Ivy/InstallSource/InstallSource.vdproj +++ b/Ivy/InstallSource/InstallSource.vdproj @@ -158,7 +158,7 @@ "Product" { "Name" = "8:Microsoft Visual Studio" - "ProductName" = "8:InstallSource" + "ProductName" = "8:IVY Sources" "ProductCode" = "8:{9C865A50-9302-4B25-B699-88A034620AEA}" "PackageCode" = "8:{0E024615-C205-43BC-9494-F7E780B27CBB}" "UpgradeCode" = "8:{779E9266-AC8C-490F-8519-7B26BDA9E0F3}" @@ -166,14 +166,14 @@ "RemovePreviousVersions" = "11:FALSE" "DetectNewerInstalledVersion" = "11:TRUE" "ProductVersion" = "8:1.0.0" - "Manufacturer" = "8:Nom de société par défaut" + "Manufacturer" = "8:CENA PII" "ARPHELPTELEPHONE" = "8:" "ARPHELPLINK" = "8:" - "Title" = "8:InstallSource" + "Title" = "8:IVY Sources" "Subject" = "8:" - "ARPCONTACT" = "8:Nom de société par défaut" - "Keywords" = "8:" - "ARPCOMMENTS" = "8:" + "ARPCONTACT" = "8:CENA PII" + "Keywords" = "8:Ivy" + "ARPCOMMENTS" = "8:Source de Ivy IvyProbe comIvy" "ARPURLINFOABOUT" = "8:" "ARPPRODUCTICON" = "8:" "ARPIconIndex" = "3:0" -- cgit v1.1 From c8c88c97e6ecd0493aed0b4e2e693d055256e761 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:20 +0000 Subject: Utilisateur : Fcolin Date : 4/01/05 Heure : 17:31 Archivé dans $/Bus/Ivy/InstallSource Commentaire: (vss 3) --- Ivy/InstallSource/InstallSource.vdproj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstallSource/InstallSource.vdproj b/Ivy/InstallSource/InstallSource.vdproj index 24d4533..2f1cac9 100644 --- a/Ivy/InstallSource/InstallSource.vdproj +++ b/Ivy/InstallSource/InstallSource.vdproj @@ -37,7 +37,7 @@ "DisplayName" = "8:Release" "IsDebugOnly" = "11:FALSE" "IsReleaseOnly" = "11:TRUE" - "OutputFilename" = "8:Release\\InstallSource.msi" + "OutputFilename" = "8:..\\..\\..\\..\\Install\\InstallSource.msi" "PackageFilesAs" = "3:2" "PackageFileSize" = "3:-2147483648" "CabType" = "3:1" @@ -46,7 +46,7 @@ "CertificateFile" = "8:" "PrivateKeyFile" = "8:" "TimeStampServer" = "8:" - "InstallerBootstrapper" = "3:2" + "InstallerBootstrapper" = "3:1" } } "Deployable" -- cgit v1.1 From 0c5f407bec2c7ef03fc8e210e00e83ead47e6752 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:22 +0000 Subject: Utilisateur : Fcolin Date : 6/01/05 Heure : 10:41 Archivé dans $/Bus/Ivy/InstallSource Commentaire: (vss 4) --- Ivy/InstallSource/InstallSource.vdproj | 34 +++------------------------------- 1 file changed, 3 insertions(+), 31 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstallSource/InstallSource.vdproj b/Ivy/InstallSource/InstallSource.vdproj index 2f1cac9..fe9a25d 100644 --- a/Ivy/InstallSource/InstallSource.vdproj +++ b/Ivy/InstallSource/InstallSource.vdproj @@ -688,12 +688,12 @@ { } } - "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_4BDAFC134AA14038BB9F9243DCCD5FFD" + "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_C9F3C54E38864BB58C113C829A63303E" { "SourcePath" = "8:" "TargetName" = "8:" "Tag" = "8:" - "Folder" = "8:_09678DC790BE461A87B4C5BE4A24046B" + "Folder" = "8:_B3B7EB8E946F45E1BA06E9D854393106" "Condition" = "8:" "Transitive" = "11:FALSE" "Vital" = "11:TRUE" @@ -710,35 +710,7 @@ "ProjectOutputGroupRegister" = "3:1" "OutputConfiguration" = "8:" "OutputGroupCanonicalName" = "8:SourceFiles" - "OutputProjectGuid" = "8:{561E32B8-AF2E-4BA4-8D1D-159CC71E2C90}" - "ShowKeyOutput" = "11:TRUE" - "ExcludeFilters" - { - } - } - "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_82D4223AEA774E18932622E6A2FF85ED" - { - "SourcePath" = "8:" - "TargetName" = "8:" - "Tag" = "8:" - "Folder" = "8:_982736CE041D479585A839B95041A4C3" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - "ProjectOutputGroupRegister" = "3:1" - "OutputConfiguration" = "8:" - "OutputGroupCanonicalName" = "8:SourceFiles" - "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" + "OutputProjectGuid" = "8:{84E0039A-6721-4B18-9792-E9AE4274AC0E}" "ShowKeyOutput" = "11:TRUE" "ExcludeFilters" { -- cgit v1.1 From 52856b54b4f51a0a3071fc1116269ebcd3354e78 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:24 +0000 Subject: Utilisateur : Fcolin Date : 6/01/05 Heure : 10:52 Archivé dans $/Bus/Ivy/InstallSource Commentaire: (vss 5) --- Ivy/InstallSource/InstallSource.vdproj | 30 ++++-------------------------- 1 file changed, 4 insertions(+), 26 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstallSource/InstallSource.vdproj b/Ivy/InstallSource/InstallSource.vdproj index fe9a25d..84b4fce 100644 --- a/Ivy/InstallSource/InstallSource.vdproj +++ b/Ivy/InstallSource/InstallSource.vdproj @@ -77,28 +77,6 @@ } "Folder" { - "{78BAF5CE-F2E5-45BE-83BC-DB6AF387E941}:_34A3F2CD942D42DBBF33B8154F9BE594" - { - "Name" = "8:#1916" - "AlwaysCreate" = "11:FALSE" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Property" = "8:DesktopFolder" - "Folders" - { - } - } - "{78BAF5CE-F2E5-45BE-83BC-DB6AF387E941}:_9A19D5AD4187451890787BE5AAD5D8A2" - { - "Name" = "8:#1919" - "AlwaysCreate" = "11:FALSE" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Property" = "8:ProgramMenuFolder" - "Folders" - { - } - } "{58C0ADA3-3CEA-43BD-A3B3-2EA121BC8217}:_B3B7EB8E946F45E1BA06E9D854393106" { "DefaultLocation" = "8:[ProgramFilesFolder][Manufacturer]\\[ProductName]" @@ -160,7 +138,7 @@ "Name" = "8:Microsoft Visual Studio" "ProductName" = "8:IVY Sources" "ProductCode" = "8:{9C865A50-9302-4B25-B699-88A034620AEA}" - "PackageCode" = "8:{0E024615-C205-43BC-9494-F7E780B27CBB}" + "PackageCode" = "8:{616F930C-4377-4C25-A208-D99CDFCC4BA1}" "UpgradeCode" = "8:{779E9266-AC8C-490F-8519-7B26BDA9E0F3}" "RestartWWWService" = "11:FALSE" "RemovePreviousVersions" = "11:FALSE" @@ -688,12 +666,12 @@ { } } - "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_C9F3C54E38864BB58C113C829A63303E" + "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_F7CCDC767F0A43859A12C6B0D26950FD" { "SourcePath" = "8:" "TargetName" = "8:" "Tag" = "8:" - "Folder" = "8:_B3B7EB8E946F45E1BA06E9D854393106" + "Folder" = "8:_982736CE041D479585A839B95041A4C3" "Condition" = "8:" "Transitive" = "11:FALSE" "Vital" = "11:TRUE" @@ -710,7 +688,7 @@ "ProjectOutputGroupRegister" = "3:1" "OutputConfiguration" = "8:" "OutputGroupCanonicalName" = "8:SourceFiles" - "OutputProjectGuid" = "8:{84E0039A-6721-4B18-9792-E9AE4274AC0E}" + "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" "ShowKeyOutput" = "11:TRUE" "ExcludeFilters" { -- cgit v1.1 From 01f274ef9c168fce7051fce30ab275f7cfab099d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:26 +0000 Subject: Utilisateur : Fcolin Date : 6/01/05 Heure : 11:24 Archivé dans $/Bus/Ivy/InstallSource Commentaire: (vss 6) --- Ivy/InstallSource/InstallSource.vdproj | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstallSource/InstallSource.vdproj b/Ivy/InstallSource/InstallSource.vdproj index 84b4fce..cfe61fa 100644 --- a/Ivy/InstallSource/InstallSource.vdproj +++ b/Ivy/InstallSource/InstallSource.vdproj @@ -87,17 +87,6 @@ "Property" = "8:TARGETDIR" "Folders" { - "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_09678DC790BE461A87B4C5BE4A24046B" - { - "Name" = "8:comIvy" - "AlwaysCreate" = "11:FALSE" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Property" = "8:_33B5EB2D56D7495C87248919CACD5442" - "Folders" - { - } - } "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_982736CE041D479585A839B95041A4C3" { "Name" = "8:Ivy" @@ -141,7 +130,7 @@ "PackageCode" = "8:{616F930C-4377-4C25-A208-D99CDFCC4BA1}" "UpgradeCode" = "8:{779E9266-AC8C-490F-8519-7B26BDA9E0F3}" "RestartWWWService" = "11:FALSE" - "RemovePreviousVersions" = "11:FALSE" + "RemovePreviousVersions" = "11:TRUE" "DetectNewerInstalledVersion" = "11:TRUE" "ProductVersion" = "8:1.0.0" "Manufacturer" = "8:CENA PII" @@ -151,7 +140,7 @@ "Subject" = "8:" "ARPCONTACT" = "8:CENA PII" "Keywords" = "8:Ivy" - "ARPCOMMENTS" = "8:Source de Ivy IvyProbe comIvy" + "ARPCOMMENTS" = "8:Source de Ivy IvyProbe " "ARPURLINFOABOUT" = "8:" "ARPPRODUCTICON" = "8:" "ARPIconIndex" = "3:0" -- cgit v1.1 From d17ef7f1803f893a5821365d54afc8420004c1c7 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:28 +0000 Subject: Utilisateur : Fcolin Date : 6/01/05 Heure : 11:38 Archivé dans $/Bus/Ivy/InstallSource Commentaire: (vss 7) --- Ivy/InstallSource/InstallSource.vdproj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstallSource/InstallSource.vdproj b/Ivy/InstallSource/InstallSource.vdproj index cfe61fa..b050b82 100644 --- a/Ivy/InstallSource/InstallSource.vdproj +++ b/Ivy/InstallSource/InstallSource.vdproj @@ -3,7 +3,7 @@ "VSVersion" = "3:701" "ProjectType" = "8:{2C2AF0D9-9B47-4FE5-BEF2-169778172667}" "IsWebType" = "8:FALSE" -"ProjectName" = "8:InstallSource" +"ProjectName" = "8:InstallIvySources" "LanguageId" = "3:1036" "CodePage" = "3:1252" "UILanguageId" = "3:1036" @@ -37,7 +37,7 @@ "DisplayName" = "8:Release" "IsDebugOnly" = "11:FALSE" "IsReleaseOnly" = "11:TRUE" - "OutputFilename" = "8:..\\..\\..\\..\\Install\\InstallSource.msi" + "OutputFilename" = "8:..\\..\\..\\..\\Install\\InstallIvySources.msi" "PackageFilesAs" = "3:2" "PackageFileSize" = "3:-2147483648" "CabType" = "3:1" -- cgit v1.1 From 88fa145984e7dd94e2cff60c542b7f02f0809ff3 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:30 +0000 Subject: Utilisateur : Fcolin Date : 8/03/05 Heure : 15:20 Archivé dans $/Bus/Ivy/InstallSource Commentaire: Bug en cas d'expression vide de subexpression (vss 8) --- Ivy/InstallSource/InstallSource.vdproj | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstallSource/InstallSource.vdproj b/Ivy/InstallSource/InstallSource.vdproj index b050b82..0e91743 100644 --- a/Ivy/InstallSource/InstallSource.vdproj +++ b/Ivy/InstallSource/InstallSource.vdproj @@ -126,13 +126,13 @@ { "Name" = "8:Microsoft Visual Studio" "ProductName" = "8:IVY Sources" - "ProductCode" = "8:{9C865A50-9302-4B25-B699-88A034620AEA}" - "PackageCode" = "8:{616F930C-4377-4C25-A208-D99CDFCC4BA1}" + "ProductCode" = "8:{A4D80C7C-E792-43F3-97D5-F163E43C2592}" + "PackageCode" = "8:{53FFC324-1905-413D-BBFB-D202926583C3}" "UpgradeCode" = "8:{779E9266-AC8C-490F-8519-7B26BDA9E0F3}" "RestartWWWService" = "11:FALSE" "RemovePreviousVersions" = "11:TRUE" "DetectNewerInstalledVersion" = "11:TRUE" - "ProductVersion" = "8:1.0.0" + "ProductVersion" = "8:1.1.0" "Manufacturer" = "8:CENA PII" "ARPHELPTELEPHONE" = "8:" "ARPHELPLINK" = "8:" -- cgit v1.1 From 28150fbad47a478297b7a2a2a79f3498fd50abf9 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:32 +0000 Subject: Utilisateur : Fcolin Date : 2/12/05 Heure : 10:00 Archivé dans $/Bus/Ivy/InstallSource Commentaire: (vss 9) --- Ivy/InstallSource/InstallSource.vdproj | 101 ++++++++++++++++++++++----------- 1 file changed, 69 insertions(+), 32 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstallSource/InstallSource.vdproj b/Ivy/InstallSource/InstallSource.vdproj index 0e91743..31cbc67 100644 --- a/Ivy/InstallSource/InstallSource.vdproj +++ b/Ivy/InstallSource/InstallSource.vdproj @@ -1,7 +1,7 @@ "DeployProject" { -"VSVersion" = "3:701" -"ProjectType" = "8:{2C2AF0D9-9B47-4FE5-BEF2-169778172667}" +"VSVersion" = "3:800" +"ProjectType" = "8:{978C614F-708E-4E1A-B201-565925725DBA}" "IsWebType" = "8:FALSE" "ProjectName" = "8:InstallIvySources" "LanguageId" = "3:1036" @@ -31,6 +31,17 @@ "PrivateKeyFile" = "8:" "TimeStampServer" = "8:" "InstallerBootstrapper" = "3:2" + "BootstrapperCfg:{63ACBE69-63AA-4F98-B2B6-99F9E24495F2}" + { + "Enabled" = "11:TRUE" + "PromptEnabled" = "11:TRUE" + "PrerequisitesLocation" = "2:1" + "Url" = "8:" + "ComponentsUrl" = "8:" + "Items" + { + } + } } "Release" { @@ -47,6 +58,17 @@ "PrivateKeyFile" = "8:" "TimeStampServer" = "8:" "InstallerBootstrapper" = "3:1" + "BootstrapperCfg:{63ACBE69-63AA-4F98-B2B6-99F9E24495F2}" + { + "Enabled" = "11:FALSE" + "PromptEnabled" = "11:TRUE" + "PrerequisitesLocation" = "2:1" + "Url" = "8:" + "ComponentsUrl" = "8:" + "Items" + { + } + } } } "Deployable" @@ -66,9 +88,6 @@ { } } - "Feature" - { - } "File" { } @@ -77,7 +96,7 @@ } "Folder" { - "{58C0ADA3-3CEA-43BD-A3B3-2EA121BC8217}:_B3B7EB8E946F45E1BA06E9D854393106" + "{3C67513D-01DD-4637-8A68-80971EB9504F}:_B3B7EB8E946F45E1BA06E9D854393106" { "DefaultLocation" = "8:[ProgramFilesFolder][Manufacturer]\\[ProductName]" "Name" = "8:#1925" @@ -87,7 +106,7 @@ "Property" = "8:TARGETDIR" "Folders" { - "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_982736CE041D479585A839B95041A4C3" + "{9EF0B969-E518-4E46-987F-47570745A589}:_982736CE041D479585A839B95041A4C3" { "Name" = "8:Ivy" "AlwaysCreate" = "11:FALSE" @@ -98,7 +117,7 @@ { } } - "{F27BD5C5-A65D-4608-96D4-7C5DA1F76302}:_D5ABE290941D4E11A32C1B4224453B50" + "{9EF0B969-E518-4E46-987F-47570745A589}:_D5ABE290941D4E11A32C1B4224453B50" { "Name" = "8:IvyProbe" "AlwaysCreate" = "11:FALSE" @@ -132,6 +151,7 @@ "RestartWWWService" = "11:FALSE" "RemovePreviousVersions" = "11:TRUE" "DetectNewerInstalledVersion" = "11:TRUE" + "InstallAllUsers" = "11:FALSE" "ProductVersion" = "8:1.1.0" "Manufacturer" = "8:CENA PII" "ARPHELPTELEPHONE" = "8:" @@ -146,6 +166,10 @@ "ARPIconIndex" = "3:0" "SearchPath" = "8:" "UseSystemSearchPath" = "11:TRUE" + "TargetPlatform" = "3:0" + "PreBuildEvent" = "8:" + "PostBuildEvent" = "8:" + "RunPostBuildEvent" = "3:0" } "Registry" { @@ -153,7 +177,7 @@ { "Keys" { - "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_53933E3AD9234F12A4873FFA9773F31B" + "{60EA8692-D2D5-43EB-80DC-7906BF13D6EF}:_53933E3AD9234F12A4873FFA9773F31B" { "Name" = "8:Software" "Condition" = "8:" @@ -162,7 +186,7 @@ "Transitive" = "11:FALSE" "Keys" { - "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_7A4AE5DE0CDC412DB0987B541DAEEA5C" + "{60EA8692-D2D5-43EB-80DC-7906BF13D6EF}:_7A4AE5DE0CDC412DB0987B541DAEEA5C" { "Name" = "8:[Manufacturer]" "Condition" = "8:" @@ -187,7 +211,7 @@ { "Keys" { - "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_44F3154318AA4F4E8261D87380278D24" + "{60EA8692-D2D5-43EB-80DC-7906BF13D6EF}:_44F3154318AA4F4E8261D87380278D24" { "Name" = "8:Software" "Condition" = "8:" @@ -196,7 +220,7 @@ "Transitive" = "11:FALSE" "Keys" { - "{6A471EEF-D31B-40F8-BCF6-C9E8EC783F36}:_9E06D03F3A794C62A13E46DD90ECF5C2" + "{60EA8692-D2D5-43EB-80DC-7906BF13D6EF}:_9E06D03F3A794C62A13E46DD90ECF5C2" { "Name" = "8:[Manufacturer]" "Condition" = "8:" @@ -244,14 +268,14 @@ } "UserInterface" { - "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_0A813400DCAA4CA2AED300FE90057CD5" + "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_0A813400DCAA4CA2AED300FE90057CD5" { "Name" = "8:#1902" "Sequence" = "3:1" "Attributes" = "3:3" "Dialogs" { - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_D10C5ED5EBA44D81A8E5ABCD373D3DFB" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_D10C5ED5EBA44D81A8E5ABCD373D3DFB" { "Sequence" = "3:100" "DisplayName" = "8:Terminé" @@ -288,14 +312,14 @@ } } } - "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_0BBD850026394B248C77CF0D6A143DCC" + "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_0BBD850026394B248C77CF0D6A143DCC" { "Name" = "8:#1901" "Sequence" = "3:2" "Attributes" = "3:2" "Dialogs" { - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_C6C426B741844BD2B3CEDB5637FA9398" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_C6C426B741844BD2B3CEDB5637FA9398" { "Sequence" = "3:100" "DisplayName" = "8:Progression" @@ -332,14 +356,14 @@ } } } - "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_138810673D2A4B039E304596343A481D" + "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_138810673D2A4B039E304596343A481D" { "Name" = "8:#1902" "Sequence" = "3:2" "Attributes" = "3:3" "Dialogs" { - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_F70B3043BFCB4E2CAE3E5D5165AEF3BE" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_F70B3043BFCB4E2CAE3E5D5165AEF3BE" { "Sequence" = "3:100" "DisplayName" = "8:Terminé" @@ -363,20 +387,20 @@ } } } - "{B654A020-6903-4E6A-A86C-75DC463DB54B}:_14D0F4EA9F4542A9A7180215B5B185E0" + "{2479F3F5-0309-486D-8047-8187E2CE5BA0}:_14D0F4EA9F4542A9A7180215B5B185E0" { "UseDynamicProperties" = "11:FALSE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdBasicDialogs.wim" } - "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_A5F428FF10E64C82A99936F0EEFE6C9A" + "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_A5F428FF10E64C82A99936F0EEFE6C9A" { "Name" = "8:#1900" "Sequence" = "3:1" "Attributes" = "3:1" "Dialogs" { - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_BC6CF4D097A54F8796A6DC0991F61A8A" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_BC6CF4D097A54F8796A6DC0991F61A8A" { "Sequence" = "3:300" "DisplayName" = "8:Confirmer l'installation" @@ -398,7 +422,7 @@ } } } - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_C59FDD5750904CE69714920B25A7A1D5" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_C59FDD5750904CE69714920B25A7A1D5" { "Sequence" = "3:200" "DisplayName" = "8:Dossier d'installation" @@ -418,9 +442,22 @@ "Setting" = "3:1" "UsePlugInResources" = "11:TRUE" } + "InstallAllUsersVisible" + { + "Name" = "8:InstallAllUsersVisible" + "DisplayName" = "8:#1059" + "Description" = "8:#1159" + "Type" = "3:5" + "ContextData" = "8:1;True=1;False=0" + "Attributes" = "3:0" + "Setting" = "3:0" + "Value" = "3:1" + "DefaultValue" = "3:1" + "UsePlugInResources" = "11:TRUE" + } } } - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_F3608A2FED224610A31E8BA94D72172B" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_F3608A2FED224610A31E8BA94D72172B" { "Sequence" = "3:100" "DisplayName" = "8:Bienvenue" @@ -470,20 +507,20 @@ } } } - "{B654A020-6903-4E6A-A86C-75DC463DB54B}:_B959F1B9EF674DF1AAAC84393D11F1F4" + "{2479F3F5-0309-486D-8047-8187E2CE5BA0}:_B959F1B9EF674DF1AAAC84393D11F1F4" { "UseDynamicProperties" = "11:FALSE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdUserInterface.wim" } - "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_BF96EE5647E446EE8E09C7161F2D15C6" + "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_BF96EE5647E446EE8E09C7161F2D15C6" { "Name" = "8:#1900" "Sequence" = "3:2" "Attributes" = "3:1" "Dialogs" { - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_5DD5731B72974577BB1FE53249896CE6" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_5DD5731B72974577BB1FE53249896CE6" { "Sequence" = "3:300" "DisplayName" = "8:Confirmer l'installation" @@ -505,7 +542,7 @@ } } } - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_6CF0FA0D246440D18CF8219B20779B9B" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_6CF0FA0D246440D18CF8219B20779B9B" { "Sequence" = "3:200" "DisplayName" = "8:Dossier d'installation" @@ -527,7 +564,7 @@ } } } - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_7232E533C8364A2481A6BF178EF00E6E" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_7232E533C8364A2481A6BF178EF00E6E" { "Sequence" = "3:100" "DisplayName" = "8:Bienvenue" @@ -577,14 +614,14 @@ } } } - "{8D9DEE8B-DD8B-4F48-9072-C4364E4F4011}:_D683AF1F16134222A207B5C3D986AFD7" + "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_D683AF1F16134222A207B5C3D986AFD7" { "Name" = "8:#1901" "Sequence" = "3:1" "Attributes" = "3:2" "Dialogs" { - "{18ADD6EC-89FE-4ED7-AD3E-211C40278470}:_6A78AB4A47D846BE8BCFE2FD4B21FED4" + "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_6A78AB4A47D846BE8BCFE2FD4B21FED4" { "Sequence" = "3:100" "DisplayName" = "8:Progression" @@ -627,7 +664,7 @@ } "ProjectOutput" { - "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_31B0D0C4AA7F433F8B505436C2D1D325" + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_31B0D0C4AA7F433F8B505436C2D1D325" { "SourcePath" = "8:" "TargetName" = "8:" @@ -655,7 +692,7 @@ { } } - "{8062640A-2EEE-46E9-AB67-688E9A886E9F}:_F7CCDC767F0A43859A12C6B0D26950FD" + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_F7CCDC767F0A43859A12C6B0D26950FD" { "SourcePath" = "8:" "TargetName" = "8:" -- cgit v1.1 From 793f9cf17472974c18610f3f1744b170641a2b4c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:34 +0000 Subject: Utilisateur : Fcolin Date : 1/08/06 Heure : 13:14 Archivé dans $/Bus/Ivy/InstallSource Commentaire: (vss 10) --- Ivy/InstallSource/InstallSource.vdproj | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'Ivy') diff --git a/Ivy/InstallSource/InstallSource.vdproj b/Ivy/InstallSource/InstallSource.vdproj index 31cbc67..72879da 100644 --- a/Ivy/InstallSource/InstallSource.vdproj +++ b/Ivy/InstallSource/InstallSource.vdproj @@ -63,7 +63,7 @@ "Enabled" = "11:FALSE" "PromptEnabled" = "11:TRUE" "PrerequisitesLocation" = "2:1" - "Url" = "8:" + "Url" = "8:http://www.tls.cena.fr/products/ivy/download/packages" "ComponentsUrl" = "8:" "Items" { @@ -146,7 +146,7 @@ "Name" = "8:Microsoft Visual Studio" "ProductName" = "8:IVY Sources" "ProductCode" = "8:{A4D80C7C-E792-43F3-97D5-F163E43C2592}" - "PackageCode" = "8:{53FFC324-1905-413D-BBFB-D202926583C3}" + "PackageCode" = "8:{6C9A2D11-2E42-486D-84E1-C0A8A0AA3FB1}" "UpgradeCode" = "8:{779E9266-AC8C-490F-8519-7B26BDA9E0F3}" "RestartWWWService" = "11:FALSE" "RemovePreviousVersions" = "11:TRUE" @@ -155,7 +155,7 @@ "ProductVersion" = "8:1.1.0" "Manufacturer" = "8:CENA PII" "ARPHELPTELEPHONE" = "8:" - "ARPHELPLINK" = "8:" + "ARPHELPLINK" = "8:http://www.tls.cena.fr/products/ivy" "Title" = "8:IVY Sources" "Subject" = "8:" "ARPCONTACT" = "8:CENA PII" @@ -168,7 +168,7 @@ "UseSystemSearchPath" = "11:TRUE" "TargetPlatform" = "3:0" "PreBuildEvent" = "8:" - "PostBuildEvent" = "8:" + "PostBuildEvent" = "8:\"$(ProjectDir)..\\..\\UpdateIvyWeb.bat\" \"$(BuiltOuputPath)\"" "RunPostBuildEvent" = "3:0" } "Registry" @@ -278,7 +278,7 @@ "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_D10C5ED5EBA44D81A8E5ABCD373D3DFB" { "Sequence" = "3:100" - "DisplayName" = "8:Terminé" + "DisplayName" = "8:Finished" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdFinishedDlg.wid" @@ -322,7 +322,7 @@ "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_C6C426B741844BD2B3CEDB5637FA9398" { "Sequence" = "3:100" - "DisplayName" = "8:Progression" + "DisplayName" = "8:Progress" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminProgressDlg.wid" @@ -366,7 +366,7 @@ "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_F70B3043BFCB4E2CAE3E5D5165AEF3BE" { "Sequence" = "3:100" - "DisplayName" = "8:Terminé" + "DisplayName" = "8:Finished" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminFinishedDlg.wid" @@ -403,7 +403,7 @@ "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_BC6CF4D097A54F8796A6DC0991F61A8A" { "Sequence" = "3:300" - "DisplayName" = "8:Confirmer l'installation" + "DisplayName" = "8:Confirm Installation" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdConfirmDlg.wid" @@ -425,7 +425,7 @@ "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_C59FDD5750904CE69714920B25A7A1D5" { "Sequence" = "3:200" - "DisplayName" = "8:Dossier d'installation" + "DisplayName" = "8:Installation Folder" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdFolderDlg.wid" @@ -460,7 +460,7 @@ "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_F3608A2FED224610A31E8BA94D72172B" { "Sequence" = "3:100" - "DisplayName" = "8:Bienvenue" + "DisplayName" = "8:Welcome" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdWelcomeDlg.wid" @@ -523,7 +523,7 @@ "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_5DD5731B72974577BB1FE53249896CE6" { "Sequence" = "3:300" - "DisplayName" = "8:Confirmer l'installation" + "DisplayName" = "8:Confirm Installation" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminConfirmDlg.wid" @@ -545,7 +545,7 @@ "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_6CF0FA0D246440D18CF8219B20779B9B" { "Sequence" = "3:200" - "DisplayName" = "8:Dossier d'installation" + "DisplayName" = "8:Installation Folder" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminFolderDlg.wid" @@ -567,7 +567,7 @@ "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_7232E533C8364A2481A6BF178EF00E6E" { "Sequence" = "3:100" - "DisplayName" = "8:Bienvenue" + "DisplayName" = "8:Welcome" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdAdminWelcomeDlg.wid" @@ -624,7 +624,7 @@ "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_6A78AB4A47D846BE8BCFE2FD4B21FED4" { "Sequence" = "3:100" - "DisplayName" = "8:Progression" + "DisplayName" = "8:Progress" "UseDynamicProperties" = "11:TRUE" "IsDependency" = "11:FALSE" "SourcePath" = "8:\\VsdProgressDlg.wid" -- cgit v1.1 From 9f0ee5f191900dc0b0d4038ad007a79e1c7c1c0c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:36 +0000 Subject: Utilisateur : Fcolin Date : 4/01/05 Heure : 14:48 Créé Commentaire: (vss 1) --- Ivy/InstallSource/InstallSource.vdproj.vspscc | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 Ivy/InstallSource/InstallSource.vdproj.vspscc (limited to 'Ivy') diff --git a/Ivy/InstallSource/InstallSource.vdproj.vspscc b/Ivy/InstallSource/InstallSource.vdproj.vspscc new file mode 100644 index 0000000..65fed18 --- /dev/null +++ b/Ivy/InstallSource/InstallSource.vdproj.vspscc @@ -0,0 +1,10 @@ +"" +{ +"FILE_VERSION" = "9237" +"ENLISTMENT_CHOICE" = "NEVER" +"PROJECT_FILE_RELATIVE_PATH" = "relative:Ivy\\InstallSource" +"NUMBER_OF_EXCLUDED_FILES" = "0" +"ORIGINAL_PROJECT_FILE_PATH" = "" +"NUMBER_OF_NESTED_PROJECTS" = "0" +"SOURCE_CONTROL_SETTINGS_PROVIDER" = "PROVIDER" +} -- cgit v1.1 From feaa8372e6a9849dae2b624a432bf38cd60d6568 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:38 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/Ivy.cxx | 304 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 304 insertions(+) create mode 100644 Ivy/Ivy.cxx (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx new file mode 100644 index 0000000..e3c6bc6 --- /dev/null +++ b/Ivy/Ivy.cxx @@ -0,0 +1,304 @@ +// Ivy.cpp: implementation of the Ivy class. +// +////////////////////////////////////////////////////////////////////// + +#include "stdafx.h" +//#include "libIvy.h" +#include "Ivy.h" + +#include "IvyWatcher.h" +#include "IvyApplication.h" +#include "IvySynchroWnd.h" + + +#define DEFAULT_ADDR "127.255.255.255" +#define SEPARATOR ":" +#define DEFAULT_PORT "2010" +#define DEFAULT_DOMAIN DEFAULT_ADDR/**/SEPARATOR/**/DEFAULT_PORT + + +////////////////////////////////////////////////////////////////////// +// Construction/Destruction +////////////////////////////////////////////////////////////////////// + + +Ivy::~Ivy() +{ + // remove all app and stop watcher + stop(); + regexp_out.clear(); + + for ( int i = 0; i < callbacks.size(); i ++) + { + delete callbacks[i]; + } + callbacks.clear(); + +// if ( direct_callback ) delete direct_callback; +// if ( application_callback ) delete application_callback; + + delete watcher; + server->Close(); + delete server; + if ( synchronous ) + { + delete IvySynchronousCallback::m_synchro; + delete application_callback; + } +} + + +Ivy::Ivy(const char* name, const char * ready, IvyApplicationCallback *callback, bool Synchronous) +{ + InitializeCriticalSection( &m_application_cs ); + + synchronous = Synchronous; + if ( synchronous ) + IvySynchronousCallback::m_synchro = new IvySynchroWnd(); + ready_message = ready; + appname = name; + messages_classes_count = 0; + messages_classes = NULL; + application_callback = synchronous ? new IvySynchronousApplicationCallback(callback) : callback; + direct_callback = NULL; + die_callback = NULL; + server = new IvyApplication(this); + applicationPort = server->Create(); + if ( !applicationPort ) + { + TRACE( " Can't Create server %d\n", server->GetLastError( ) ); + return; + } + watcher = new IvyWatcher(this); + + +} +const char * Ivy::GetDomain(const char *domainlist) +{ + // determine domain to use + // the syntax of domain is "IpBroadcastAddr1,IpBroadcastAddr2,IpBroadcastAddr2:port" + if ( domainlist ) + { + domain = domainlist; + } + if ( domain.empty() ) + { + domain = getenv ( "IVYBUS" ); + if ( domain.empty() ) + domain = DEFAULT_DOMAIN; + } + // first find our UDP port + int sep_index = domain.rfind( ':' ); + if ( sep_index == -1 ) + { + domain = DEFAULT_DOMAIN; + TRACE(" Missing ':' in domain list using default domain %s\n", domain.c_str() ); + } + if ( sep_index == 0 ) + { + /* missing addr using localhost */ + domain.insert(0,DEFAULT_ADDR); + } + return domain.c_str(); +} + +void Ivy::start(const char *domain) +{ + watcher->start(domain); +} +void Ivy::stop() +{ + watcher->stop(); + + for ( int pos = 0 ; pos < applications.size() ; pos++ ) + { + IvyApplication *app = applications[pos]; + delete app; + } + applications.clear(); +} +int Ivy::BindMsg(const char *regexp, IvyMessageCallback *cb) +{ + static int id = 0; + regexp_out.push_back( regexp ); + callbacks.push_back( synchronous ? new IvySynchronousMessageCallback(cb) : cb ); + + /* send to already connected */ + for ( int pos = 0 ; pos < applications.size() ; pos ++ ) + { + IvyApplication *app = applications[ pos ]; + app->SendMsg(IvyApplication::AddRegexp, id, regexp ); + } + return id++; +} + +void Ivy::UnbindMsg(int id) +{ + regexp_out[ id ] = ""; + callbacks[ id ] = NULL; + /* send to already connected */ + for ( int pos = 0 ; pos < applications.size(); pos ++ ) + { + IvyApplication *app = applications[ pos ]; + app->SendMsg(IvyApplication::DelRegexp, id, "" ); + } + +} + +void Ivy::BindDirectMsg(IvyDirectMessageCallback *callback) +{ +direct_callback = callback; +} + +UINT Ivy::GetApplicationPort() +{ + return applicationPort; +} + +void Ivy::AddApplication(IvyApplication *app) +{ + EnterCriticalSection( &m_application_cs ); + // Check for disconnected Application + for ( int pos = 0; pos < applications.size(); pos ++ ) + { + IvyApplication *disc_app = applications[ pos ]; + if ( disc_app->m_hSocket == INVALID_SOCKET ) + { + //applications.erase( pos ); + delete disc_app; + } + } + applications.push_back( app ); + LeaveCriticalSection( &m_application_cs ); + SendSubscriptions( app ); +} +void Ivy::RemoveApplication(IvyApplication * app) +{ + /// OLD NOT called because of deallocation PB + // the real remove is done at arrival of a new Application + // or at the bus Stop + assert( TRUE ); + if ( app ) + { + for ( int pos = 0; pos < applications.size(); pos ++ ) + { + if ( app == applications[ pos ] ) + { + EnterCriticalSection( &m_application_cs ); + //applications.erase( pos ); + LeaveCriticalSection( &m_application_cs ); + delete app; + } + } + } +} + +void Ivy::SendSubscriptions(IvyApplication *app) +{ + app->SendMsg( IvyApplication::StartRegexp, GetApplicationPort(), appname.c_str()); + for ( int id = 0 ; id < regexp_out.size(); id++ ) + { + const string& regexp = regexp_out[id]; + if ( !regexp.empty() ) + app->SendMsg( IvyApplication::AddRegexp, id, regexp.c_str()); + } + app->SendMsg( IvyApplication::EndRegexp, 0); + +} + + +int Ivy::SendMsg(const char * message) +{ + int count = 0; + /* send to already connected */ + for ( int pos = 0 ; pos < applications.size(); pos ++ ) + { + IvyApplication *app = applications[ pos ]; + count += app->SendMsg( message ); + } + return count; +} + + +void Ivy::CallMessageCallback(IvyApplication *app, int id, int argc, const char ** argv) +{ + IvyMessageCallback *callback; + callback = callbacks[ id ]; + if ( callback ) + { + callback->OnMessage( app, argc, argv ); + } +} + +void Ivy::CallDirectMessageCallback(IvyApplication *app, int id, const char *arg) +{ + if ( direct_callback ) + { + direct_callback->OnDirectMessage( app, id, arg ); + } +} + +BOOL Ivy::CallDieCallback(IvyApplication *app, int id, const char *arg) +{ + if ( die_callback ) + { + return die_callback->OnDie( app, id, arg ); + } + return TRUE; +} + +void Ivy::CallApplicationConnectedCallback(IvyApplication * app) +{ + if ( application_callback ) + { + application_callback->OnApplicationConnected( app ); + } +} +void Ivy::CallApplicationDisconnectedCallback(IvyApplication * app) +{ + if ( application_callback ) + { + application_callback->OnApplicationDisconnected( app ); + } +} +void Ivy::SendDirectMsg(IvyApplication * app, int id, const char *message) +{ + app->SendMsg( IvyApplication::DirectMsg, id, message ); +} + +BOOL Ivy::CheckRegexp(const char * exp) +{ + /* accepte tout par default */ + int i; + int regexp_ok = 1; + if ( *exp =='^' && messages_classes_count !=0 ) + { + regexp_ok = 0; + for ( i = 0 ; i < messages_classes_count; i++ ) + { + if (strncmp( messages_classes[i], exp+1, strlen( messages_classes[i] )) == 0) + return 1; + } + } + return regexp_ok; +} + +void Ivy::Classes(int argc, const char **argv ) +{ + messages_classes_count = argc; + messages_classes = argv; +} + +BOOL Ivy::CheckConnected(IvyApplication * app) +{ + if (app->remoteService == 0) /* old application dont check */ + return false; + /* check to see if app already connected */ + for ( int pos = 0; pos < applications.size(); pos++ ) + { + IvyApplication *application = applications[ pos ]; + if ( application != app && application->SameApplication(app)) + return true; + } + return false; +} -- cgit v1.1 From 574e115b9a6ee3e2469084a874bfa04f18316208 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:40 +0000 Subject: Utilisateur : Fcolin Date : 30/06/00 Heure : 9:37 Archivé dans $/Ivy Commentaire: bug si pas de IVYBUS (vss 2) --- Ivy/Ivy.cxx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index e3c6bc6..fd762b6 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -83,7 +83,9 @@ const char * Ivy::GetDomain(const char *domainlist) } if ( domain.empty() ) { - domain = getenv ( "IVYBUS" ); + const char *env = getenv ( "IVYBUS" ); + if ( env ) + domain = env; if ( domain.empty() ) domain = DEFAULT_DOMAIN; } -- cgit v1.1 From 04c9642429d5008dd5cb6a90ca7fa544c20d6fc8 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:42 +0000 Subject: Utilisateur : Fcolin Date : 20/07/00 Heure : 10:57 Archivé dans $/Ivy (vss 3) --- Ivy/Ivy.cxx | 41 +++++++++++++++++++++-------------------- 1 file changed, 21 insertions(+), 20 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index fd762b6..9091264 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -112,9 +112,10 @@ void Ivy::stop() { watcher->stop(); - for ( int pos = 0 ; pos < applications.size() ; pos++ ) + IvyApplicationList::iterator iter; + for ( iter = applications.begin() ; iter != applications.end() ; ++iter ) { - IvyApplication *app = applications[pos]; + IvyApplication *app = *iter; delete app; } applications.clear(); @@ -126,9 +127,10 @@ int Ivy::BindMsg(const char *regexp, IvyMessageCallback *cb) callbacks.push_back( synchronous ? new IvySynchronousMessageCallback(cb) : cb ); /* send to already connected */ - for ( int pos = 0 ; pos < applications.size() ; pos ++ ) + IvyApplicationList::iterator iter; + for ( iter = applications.begin() ; iter != applications.end() ; ++iter ) { - IvyApplication *app = applications[ pos ]; + IvyApplication *app = *iter; app->SendMsg(IvyApplication::AddRegexp, id, regexp ); } return id++; @@ -139,9 +141,10 @@ void Ivy::UnbindMsg(int id) regexp_out[ id ] = ""; callbacks[ id ] = NULL; /* send to already connected */ - for ( int pos = 0 ; pos < applications.size(); pos ++ ) + IvyApplicationList::iterator iter; + for ( iter = applications.begin() ; iter != applications.end() ; ++iter ) { - IvyApplication *app = applications[ pos ]; + IvyApplication *app = *iter; app->SendMsg(IvyApplication::DelRegexp, id, "" ); } @@ -161,12 +164,13 @@ void Ivy::AddApplication(IvyApplication *app) { EnterCriticalSection( &m_application_cs ); // Check for disconnected Application - for ( int pos = 0; pos < applications.size(); pos ++ ) + IvyApplicationList::iterator iter; + for ( iter = applications.begin() ; iter != applications.end() ; ) { - IvyApplication *disc_app = applications[ pos ]; + IvyApplication *disc_app = *iter++; if ( disc_app->m_hSocket == INVALID_SOCKET ) { - //applications.erase( pos ); + applications.remove( disc_app ); delete disc_app; } } @@ -182,16 +186,11 @@ void Ivy::RemoveApplication(IvyApplication * app) assert( TRUE ); if ( app ) { - for ( int pos = 0; pos < applications.size(); pos ++ ) - { - if ( app == applications[ pos ] ) - { + EnterCriticalSection( &m_application_cs ); - //applications.erase( pos ); + applications.remove( app ); LeaveCriticalSection( &m_application_cs ); delete app; - } - } } } @@ -213,9 +212,10 @@ int Ivy::SendMsg(const char * message) { int count = 0; /* send to already connected */ - for ( int pos = 0 ; pos < applications.size(); pos ++ ) + IvyApplicationList::iterator iter; + for ( iter = applications.begin() ; iter != applications.end() ; ++iter ) { - IvyApplication *app = applications[ pos ]; + IvyApplication *app = *iter; count += app->SendMsg( message ); } return count; @@ -296,9 +296,10 @@ BOOL Ivy::CheckConnected(IvyApplication * app) if (app->remoteService == 0) /* old application dont check */ return false; /* check to see if app already connected */ - for ( int pos = 0; pos < applications.size(); pos++ ) + IvyApplicationList::iterator iter; + for ( iter = applications.begin() ; iter != applications.end() ; ++iter ) { - IvyApplication *application = applications[ pos ]; + IvyApplication *application = *iter; if ( application != app && application->SameApplication(app)) return true; } -- cgit v1.1 From 570fc607cb946a8caa2ef7536e024c617df4d243 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:44 +0000 Subject: Utilisateur : Fcolin Date : 23/01/01 Heure : 13:12 Archivé dans $/Ivy Commentaire: remove 'using name space std;' (vss 4) --- Ivy/Ivy.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 9091264..7ab5ac9 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -199,7 +199,7 @@ void Ivy::SendSubscriptions(IvyApplication *app) app->SendMsg( IvyApplication::StartRegexp, GetApplicationPort(), appname.c_str()); for ( int id = 0 ; id < regexp_out.size(); id++ ) { - const string& regexp = regexp_out[id]; + const String& regexp = regexp_out[id]; if ( !regexp.empty() ) app->SendMsg( IvyApplication::AddRegexp, id, regexp.c_str()); } -- cgit v1.1 From c3cb3ebbf3e254a0a1e5c0837ff410d44987e87c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:46 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 5) --- Ivy/Ivy.cxx | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 7ab5ac9..54b7069 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -83,9 +83,11 @@ const char * Ivy::GetDomain(const char *domainlist) } if ( domain.empty() ) { +#ifdef _WIN_CE const char *env = getenv ( "IVYBUS" ); if ( env ) domain = env; +#endif if ( domain.empty() ) domain = DEFAULT_DOMAIN; } @@ -94,7 +96,7 @@ const char * Ivy::GetDomain(const char *domainlist) if ( sep_index == -1 ) { domain = DEFAULT_DOMAIN; - TRACE(" Missing ':' in domain list using default domain %s\n", domain.c_str() ); + TRACE(" Missing ':' in domain list using default domain %s\n", domain ); } if ( sep_index == 0 ) { @@ -155,7 +157,7 @@ void Ivy::BindDirectMsg(IvyDirectMessageCallback *callback) direct_callback = callback; } -UINT Ivy::GetApplicationPort() +unsigned short Ivy::GetApplicationPort() { return applicationPort; } @@ -183,7 +185,7 @@ void Ivy::RemoveApplication(IvyApplication * app) /// OLD NOT called because of deallocation PB // the real remove is done at arrival of a new Application // or at the bus Stop - assert( TRUE ); + ASSERT( TRUE ); if ( app ) { @@ -199,7 +201,7 @@ void Ivy::SendSubscriptions(IvyApplication *app) app->SendMsg( IvyApplication::StartRegexp, GetApplicationPort(), appname.c_str()); for ( int id = 0 ; id < regexp_out.size(); id++ ) { - const String& regexp = regexp_out[id]; + const string& regexp = regexp_out[id]; if ( !regexp.empty() ) app->SendMsg( IvyApplication::AddRegexp, id, regexp.c_str()); } @@ -240,7 +242,7 @@ void Ivy::CallDirectMessageCallback(IvyApplication *app, int id, const char *ar } } -BOOL Ivy::CallDieCallback(IvyApplication *app, int id, const char *arg) +bool Ivy::CallDieCallback(IvyApplication *app, int id, const char *arg) { if ( die_callback ) { @@ -268,14 +270,14 @@ void Ivy::SendDirectMsg(IvyApplication * app, int id, const char *message) app->SendMsg( IvyApplication::DirectMsg, id, message ); } -BOOL Ivy::CheckRegexp(const char * exp) +bool Ivy::CheckRegexp(const char * exp) { /* accepte tout par default */ int i; - int regexp_ok = 1; + bool regexp_ok = true; if ( *exp =='^' && messages_classes_count !=0 ) { - regexp_ok = 0; + regexp_ok = false; for ( i = 0 ; i < messages_classes_count; i++ ) { if (strncmp( messages_classes[i], exp+1, strlen( messages_classes[i] )) == 0) @@ -291,7 +293,7 @@ void Ivy::Classes(int argc, const char **argv ) messages_classes = argv; } -BOOL Ivy::CheckConnected(IvyApplication * app) +bool Ivy::CheckConnected(IvyApplication * app) { if (app->remoteService == 0) /* old application dont check */ return false; -- cgit v1.1 From e0729eb3b7aed25acde9992dad2e4614fda677de Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:48 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 6) --- Ivy/Ivy.cxx | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 54b7069..6284c0c 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -3,7 +3,13 @@ ////////////////////////////////////////////////////////////////////// #include "stdafx.h" -//#include "libIvy.h" + +#ifdef _DEBUG +#define DEBUG_NEW new(__FILE__, __LINE__) +#define new DEBUG_NEW +#endif + + #include "Ivy.h" #include "IvyWatcher.h" @@ -28,7 +34,7 @@ Ivy::~Ivy() stop(); regexp_out.clear(); - for ( int i = 0; i < callbacks.size(); i ++) + for ( unsigned int i = 0; i < callbacks.size(); i ++) { delete callbacks[i]; } @@ -199,7 +205,7 @@ void Ivy::RemoveApplication(IvyApplication * app) void Ivy::SendSubscriptions(IvyApplication *app) { app->SendMsg( IvyApplication::StartRegexp, GetApplicationPort(), appname.c_str()); - for ( int id = 0 ; id < regexp_out.size(); id++ ) + for ( unsigned int id = 0 ; id < regexp_out.size(); id++ ) { const string& regexp = regexp_out[id]; if ( !regexp.empty() ) -- cgit v1.1 From ddfc3e0fa9d9fbf86d2d8ca1ead9ab4223d27dd1 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:50 +0000 Subject: Utilisateur : Fcolin Date : 14/02/01 Heure : 18:47 Archivé dans $/Ivy (vss 7) --- Ivy/Ivy.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 6284c0c..561031c 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -44,7 +44,7 @@ Ivy::~Ivy() // if ( application_callback ) delete application_callback; delete watcher; - server->Close(); +// server->Close(); delete server; if ( synchronous ) { -- cgit v1.1 From 00cf18f4f75ac42dad7337ad22c1808e53b62a3e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:52 +0000 Subject: Utilisateur : Fcolin Date : 20/02/01 Heure : 10:27 Archivé dans $/Ivy (vss 8) --- Ivy/Ivy.cxx | 1 - 1 file changed, 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 561031c..3f8daed 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -9,7 +9,6 @@ #define new DEBUG_NEW #endif - #include "Ivy.h" #include "IvyWatcher.h" -- cgit v1.1 From 121227691c09257a90493aa8dbf0a57f2f8ad199 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:54 +0000 Subject: Utilisateur : Fcolin Date : 17/07/01 Heure : 18:25 Archivé dans $/Ivy (vss 9) --- Ivy/Ivy.cxx | 5 ----- 1 file changed, 5 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 3f8daed..c56356c 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -4,11 +4,6 @@ #include "stdafx.h" -#ifdef _DEBUG -#define DEBUG_NEW new(__FILE__, __LINE__) -#define new DEBUG_NEW -#endif - #include "Ivy.h" #include "IvyWatcher.h" -- cgit v1.1 From 9af56b54bfcef47df42532d79ab7743548e32c0b Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:56 +0000 Subject: Utilisateur : Fcolin Date : 25/10/01 Heure : 18:39 Archivé dans $/Ivy (vss 10) --- Ivy/Ivy.cxx | 33 +++++++++++++++++++++++++++++---- 1 file changed, 29 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index c56356c..3906333 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -83,7 +83,7 @@ const char * Ivy::GetDomain(const char *domainlist) } if ( domain.empty() ) { -#ifdef _WIN_CE +#ifndef _WIN_CE const char *env = getenv ( "IVYBUS" ); if ( env ) domain = env; @@ -210,19 +210,44 @@ void Ivy::SendSubscriptions(IvyApplication *app) } -int Ivy::SendMsg(const char * message) +int Ivy::SendMsg(const char * message, ... ) { int count = 0; + char buffer[4096]; + va_list args; + + va_start( args, message ); /* Initialize variable arguments. */ + vsprintf( buffer, message, args ); + va_end( args); /* send to already connected */ IvyApplicationList::iterator iter; for ( iter = applications.begin() ; iter != applications.end() ; ++iter ) { IvyApplication *app = *iter; - count += app->SendMsg( message ); + count += app->SendMsg( buffer ); } return count; } - +void Ivy::SendDieMsg( IvyApplication *app ) +{ + app->SendMsg( IvyApplication::Die, 0 ); +} +IvyApplication * Ivy::GetApplication(const char *name) +{ + EnterCriticalSection( &m_application_cs ); + IvyApplicationList::iterator iter; + for ( iter = applications.begin() ; iter != applications.end() ; ) + { + IvyApplication *app = *iter++; + if ( (app->m_hSocket != INVALID_SOCKET) && app->appname == name ) + { + return app; + } + } + LeaveCriticalSection( &m_application_cs ); + return NULL; +} + void Ivy::CallMessageCallback(IvyApplication *app, int id, int argc, const char ** argv) { -- cgit v1.1 From 49ebd55611e86e6fc63d8afcc38888c5991799fc Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:55:58 +0000 Subject: Utilisateur : Fcolin Date : 7/06/02 Heure : 9:35 Archivé dans $/Ivy (vss 11) --- Ivy/Ivy.cxx | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 3906333..c10785f 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -28,11 +28,15 @@ Ivy::~Ivy() stop(); regexp_out.clear(); - for ( unsigned int i = 0; i < callbacks.size(); i ++) - { + if ( synchronous ) + { + for ( unsigned int i = 0; i < callbacks.size(); i ++) + { delete callbacks[i]; - } + } + } callbacks.clear(); + // if ( direct_callback ) delete direct_callback; // if ( application_callback ) delete application_callback; -- cgit v1.1 From 3b071ef64481621c5fdea7c0117ff88407b87269 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:00 +0000 Subject: Utilisateur : Fcolin Date : 19/06/02 Heure : 15:14 Archivé dans $/Ivy (vss 12) --- Ivy/Ivy.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index c10785f..a6757c2 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -161,7 +161,7 @@ void Ivy::BindDirectMsg(IvyDirectMessageCallback *callback) direct_callback = callback; } -unsigned short Ivy::GetApplicationPort() +unsigned int Ivy::GetApplicationPort() { return applicationPort; } -- cgit v1.1 From b92f4c6128c14ad1c63a37a9d71cc2b0e42c056f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:02 +0000 Subject: Utilisateur : Fcolin Date : 25/11/02 Heure : 16:15 Archivé dans $/Bus/Ivy Commentaire: (vss 13) --- Ivy/Ivy.cxx | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index a6757c2..e5b11ea 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -122,6 +122,7 @@ void Ivy::stop() for ( iter = applications.begin() ; iter != applications.end() ; ++iter ) { IvyApplication *app = *iter; + app->Close(); delete app; } applications.clear(); -- cgit v1.1 From 8538e20f9ef0bb69a6b7a82f8b46e662d59ce398 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:04 +0000 Subject: Utilisateur : Fcolin Date : 6/01/03 Heure : 14:47 Archivé dans $/Bus/Ivy Commentaire: (vss 14) --- Ivy/Ivy.cxx | 29 +++++++++++++++++++++++++---- 1 file changed, 25 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index e5b11ea..8b26e77 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -27,6 +27,7 @@ Ivy::~Ivy() // remove all app and stop watcher stop(); regexp_out.clear(); + if ( synchronous ) { @@ -55,7 +56,7 @@ Ivy::~Ivy() Ivy::Ivy(const char* name, const char * ready, IvyApplicationCallback *callback, bool Synchronous) { InitializeCriticalSection( &m_application_cs ); - + regexp_id = 0; synchronous = Synchronous; if ( synchronous ) IvySynchronousCallback::m_synchro = new IvySynchroWnd(); @@ -129,7 +130,6 @@ void Ivy::stop() } int Ivy::BindMsg(const char *regexp, IvyMessageCallback *cb) { - static int id = 0; regexp_out.push_back( regexp ); callbacks.push_back( synchronous ? new IvySynchronousMessageCallback(cb) : cb ); @@ -138,11 +138,32 @@ int Ivy::BindMsg(const char *regexp, IvyMessageCallback *cb) for ( iter = applications.begin() ; iter != applications.end() ; ++iter ) { IvyApplication *app = *iter; - app->SendMsg(IvyApplication::AddRegexp, id, regexp ); + app->SendMsg(IvyApplication::AddRegexp, regexp_id, regexp ); } - return id++; + return regexp_id++; } +int Ivy::BindMsg( IvyMessageCallback *cb, const char *regexp, ... ) +{ + char buffer[4096]; + va_list args; + + va_start( args, regexp ); /* Initialize variable arguments. */ + vsprintf( buffer, regexp, args ); + va_end( args); + + regexp_out.push_back( regexp ); + callbacks.push_back( synchronous ? new IvySynchronousMessageCallback(cb) : cb ); + /* send to already connected */ + IvyApplicationList::iterator iter; + for ( iter = applications.begin() ; iter != applications.end() ; ++iter ) + { + IvyApplication *app = *iter; + app->SendMsg(IvyApplication::AddRegexp, regexp_id, buffer ); + } + return regexp_id++; +} + void Ivy::UnbindMsg(int id) { regexp_out[ id ] = ""; -- cgit v1.1 From 9477367dc0a9a232bf57edaa5e1e2595bb70cba7 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:06 +0000 Subject: Utilisateur : Fcolin Date : 4/02/03 Heure : 8:59 Archivé dans $/Bus/Ivy Commentaire: (vss 15) --- Ivy/Ivy.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 8b26e77..b592c11 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -88,7 +88,7 @@ const char * Ivy::GetDomain(const char *domainlist) } if ( domain.empty() ) { -#ifndef _WIN_CE +#ifndef UNDER_CE const char *env = getenv ( "IVYBUS" ); if ( env ) domain = env; -- cgit v1.1 From 3f87f03a578226cd5a8700889deb6f2a06264b9e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:08 +0000 Subject: Utilisateur : Fcolin Date : 30/09/03 Heure : 16:49 Archivé dans $/Bus/Ivy Commentaire: (vss 16) --- Ivy/Ivy.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index b592c11..609733d 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -101,7 +101,7 @@ const char * Ivy::GetDomain(const char *domainlist) if ( sep_index == -1 ) { domain = DEFAULT_DOMAIN; - TRACE(" Missing ':' in domain list using default domain %s\n", domain ); + TRACE(" Missing ':' in domain list using default domain %s\n", domain.c_str() ); } if ( sep_index == 0 ) { -- cgit v1.1 From f2271c04c9c833d3c4c8a9dc2d5cd579cb97913d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:10 +0000 Subject: Utilisateur : Fcolin Date : 5/02/04 Heure : 18:32 Archivé dans $/Bus/Ivy Commentaire: (vss 17) --- Ivy/Ivy.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 609733d..b592c11 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -101,7 +101,7 @@ const char * Ivy::GetDomain(const char *domainlist) if ( sep_index == -1 ) { domain = DEFAULT_DOMAIN; - TRACE(" Missing ':' in domain list using default domain %s\n", domain.c_str() ); + TRACE(" Missing ':' in domain list using default domain %s\n", domain ); } if ( sep_index == 0 ) { -- cgit v1.1 From d05917942b4a46fccad770655235fbfdc06bbf99 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:12 +0000 Subject: Utilisateur : Fcolin Date : 12/05/05 Heure : 14:05 Archivé dans $/Bus/Ivy Commentaire: Bug dans Ivy GetApplication ( name ) pas de release de la section critique!! (vss 18) --- Ivy/Ivy.cxx | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index b592c11..e7505d1 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -260,18 +260,20 @@ void Ivy::SendDieMsg( IvyApplication *app ) } IvyApplication * Ivy::GetApplication(const char *name) { + IvyApplication *app = NULL; EnterCriticalSection( &m_application_cs ); IvyApplicationList::iterator iter; for ( iter = applications.begin() ; iter != applications.end() ; ) { - IvyApplication *app = *iter++; - if ( (app->m_hSocket != INVALID_SOCKET) && app->appname == name ) + IvyApplication *ap = *iter++; + if ( (ap->m_hSocket != INVALID_SOCKET) && ap->appname == name ) { - return app; + app = ap; + break; // dont return because of LeaveCriticalSection !!! } } LeaveCriticalSection( &m_application_cs ); - return NULL; + return app; } -- cgit v1.1 From b1d9a197c185ccc3b0f67ee55713f16cdebad461 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:14 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:45 Archivé dans $/Bus/Ivy Commentaire: (vss 19) --- Ivy/Ivy.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index e7505d1..7cd8dde 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -2,7 +2,7 @@ // ////////////////////////////////////////////////////////////////////// -#include "stdafx.h" +#include "IvyStdAfx.h" #include "Ivy.h" @@ -148,7 +148,7 @@ int Ivy::BindMsg( IvyMessageCallback *cb, const char *regexp, ... ) va_list args; va_start( args, regexp ); /* Initialize variable arguments. */ - vsprintf( buffer, regexp, args ); + _vsnprintf( buffer, sizeof(buffer), regexp, args ); va_end( args); regexp_out.push_back( regexp ); @@ -243,7 +243,7 @@ int Ivy::SendMsg(const char * message, ... ) va_list args; va_start( args, message ); /* Initialize variable arguments. */ - vsprintf( buffer, message, args ); + _vsnprintf( buffer, sizeof(buffer), message, args ); va_end( args); /* send to already connected */ IvyApplicationList::iterator iter; -- cgit v1.1 From 36b8ea1503500ad1e4220090b90f1b0001da896f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:16 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 20) --- Ivy/Ivy.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 7cd8dde..3ef0ce2 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -227,7 +227,7 @@ void Ivy::SendSubscriptions(IvyApplication *app) app->SendMsg( IvyApplication::StartRegexp, GetApplicationPort(), appname.c_str()); for ( unsigned int id = 0 ; id < regexp_out.size(); id++ ) { - const string& regexp = regexp_out[id]; + const ivy::string& regexp = regexp_out[id]; if ( !regexp.empty() ) app->SendMsg( IvyApplication::AddRegexp, id, regexp.c_str()); } -- cgit v1.1 From e2773f2d3c326d4492311332cedbc33dc71d9205 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:18 +0000 Subject: Utilisateur : Fcolin Date : 23/09/05 Heure : 15:27 Archivé dans $/Bus/Ivy Commentaire: (vss 21) --- Ivy/Ivy.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 3ef0ce2..c70d23f 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -97,7 +97,7 @@ const char * Ivy::GetDomain(const char *domainlist) domain = DEFAULT_DOMAIN; } // first find our UDP port - int sep_index = domain.rfind( ':' ); + size_t sep_index = domain.rfind( ':' ); if ( sep_index == -1 ) { domain = DEFAULT_DOMAIN; -- cgit v1.1 From 875e598e3e1b09ee41a3aeaefc3b8bc78ac68d48 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:20 +0000 Subject: Utilisateur : Fcolin Date : 16/11/05 Heure : 9:54 Archivé dans $/Bus/Ivy Commentaire: 64 bits ports (vss 22) --- Ivy/Ivy.cxx | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index c70d23f..daa2129 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -89,9 +89,17 @@ const char * Ivy::GetDomain(const char *domainlist) if ( domain.empty() ) { #ifndef UNDER_CE - const char *env = getenv ( "IVYBUS" ); - if ( env ) + size_t requiredSize; + + getenv_s( &requiredSize, NULL, 0, "IVYBUS"); + + if ( requiredSize ) + { + char *env = (char*)malloc( requiredSize * sizeof(char)); + getenv_s( &requiredSize, env, requiredSize, "IVYBUS"); domain = env; + free( env ); + } #endif if ( domain.empty() ) domain = DEFAULT_DOMAIN; @@ -148,7 +156,7 @@ int Ivy::BindMsg( IvyMessageCallback *cb, const char *regexp, ... ) va_list args; va_start( args, regexp ); /* Initialize variable arguments. */ - _vsnprintf( buffer, sizeof(buffer), regexp, args ); + _vsnprintf_s( buffer, sizeof(buffer), sizeof(buffer)-1, regexp, args ); va_end( args); regexp_out.push_back( regexp ); @@ -243,7 +251,7 @@ int Ivy::SendMsg(const char * message, ... ) va_list args; va_start( args, message ); /* Initialize variable arguments. */ - _vsnprintf( buffer, sizeof(buffer), message, args ); + _vsnprintf_s( buffer, sizeof(buffer), sizeof(buffer)-1, message, args ); va_end( args); /* send to already connected */ IvyApplicationList::iterator iter; -- cgit v1.1 From e5faff1c9281641151f0fb6cff53d223fc1d1b91 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:22 +0000 Subject: Utilisateur : Fcolin Date : 18/11/05 Heure : 11:46 Archivé dans $/Bus/Ivy Commentaire: repassage a la STL et correction bug multithread (vss 23) --- Ivy/Ivy.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index daa2129..49be33b 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -219,7 +219,7 @@ void Ivy::RemoveApplication(IvyApplication * app) /// OLD NOT called because of deallocation PB // the real remove is done at arrival of a new Application // or at the bus Stop - ASSERT( TRUE ); + TRACE( "Ivy::RemoveApplication %lu\n", app ); if ( app ) { -- cgit v1.1 From 4012d9d589b8063a57be612b913dfa7270f5a017 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:24 +0000 Subject: Utilisateur : Fcolin Date : 23/05/06 Heure : 18:18 Archivé dans $/Bus/Ivy Commentaire: Modification protocol UDP (vss 24) --- Ivy/Ivy.cxx | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 49be33b..66c1715 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -61,7 +61,7 @@ Ivy::Ivy(const char* name, const char * ready, IvyApplicationCallback *callback, if ( synchronous ) IvySynchronousCallback::m_synchro = new IvySynchroWnd(); ready_message = ready; - appname = name; + ApplicationName = name; messages_classes_count = 0; messages_classes = NULL; application_callback = synchronous ? new IvySynchronousApplicationCallback(callback) : callback; @@ -74,10 +74,21 @@ Ivy::Ivy(const char* name, const char * ready, IvyApplicationCallback *callback, TRACE( " Can't Create server %d\n", server->GetLastError( ) ); return; } + ApplicationID = GenApplicationUniqueIdentifier(); watcher = new IvyWatcher(this); } +const char *Ivy::GenApplicationUniqueIdentifier() +{ + static char appid[2048]; + long curtime; + curtime = GetTickCount(); + srand( curtime ); + sprintf(appid,"%d:%ld:%d",rand(),curtime,applicationPort); + return appid; +} + const char * Ivy::GetDomain(const char *domainlist) { // determine domain to use @@ -232,7 +243,7 @@ void Ivy::RemoveApplication(IvyApplication * app) void Ivy::SendSubscriptions(IvyApplication *app) { - app->SendMsg( IvyApplication::StartRegexp, GetApplicationPort(), appname.c_str()); + app->SendMsg( IvyApplication::StartRegexp, GetApplicationPort(), ApplicationName.c_str()); for ( unsigned int id = 0 ; id < regexp_out.size(); id++ ) { const ivy::string& regexp = regexp_out[id]; -- cgit v1.1 From 3e928d698cf896b413b894a5c2df83562872ec4f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:26 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 10:14 Archivé dans $/Bus/Ivy Commentaire: ajout Binding Callback et SetFilter (vss 25) --- Ivy/Ivy.cxx | 30 ++++++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 66c1715..2da3766 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -64,6 +64,7 @@ Ivy::Ivy(const char* name, const char * ready, IvyApplicationCallback *callback, ApplicationName = name; messages_classes_count = 0; messages_classes = NULL; + binding_callback = NULL; application_callback = synchronous ? new IvySynchronousApplicationCallback(callback) : callback; direct_callback = NULL; die_callback = NULL; @@ -337,6 +338,27 @@ void Ivy::CallApplicationDisconnectedCallback(IvyApplication * app) application_callback->OnApplicationDisconnected( app ); } } +void Ivy::CallBindingAddCallback(IvyApplication * app, int id, const char * regexp) +{ + if ( binding_callback ) + { + binding_callback->OnAddBind( app, id, regexp ); + } +} +void Ivy::CallBindingRemoveCallback(IvyApplication * app, int id, const char * regexp) +{ + if ( binding_callback ) + { + binding_callback->OnRemoveBind( app, id, regexp ); + } +} +void Ivy::CallBindingFilterCallback(IvyApplication * app, int id, const char * regexp) +{ + if ( binding_callback ) + { + binding_callback->OnFilterBind( app, id, regexp ); + } +} void Ivy::SendDirectMsg(IvyApplication * app, int id, const char *message) { app->SendMsg( IvyApplication::DirectMsg, id, message ); @@ -358,8 +380,12 @@ bool Ivy::CheckRegexp(const char * exp) } return regexp_ok; } - -void Ivy::Classes(int argc, const char **argv ) +void Ivy::SetBindCallback( IvyBindingCallback* bind_callback ) +{ + binding_callback = synchronous ? new IvySynchronousBindingCallback(bind_callback) : bind_callback; +} + +void Ivy::SetFilter(int argc, const char **argv ) { messages_classes_count = argc; messages_classes = argv; -- cgit v1.1 From d7ee0aeb171c78ab5ec980d869ae67747a9bc87c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:28 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 15:54 Archivé dans $/Bus/Ivy Commentaire: Separation module de traitement regexp (vss 26) --- Ivy/Ivy.cxx | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 2da3766..60ba574 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -9,7 +9,7 @@ #include "IvyWatcher.h" #include "IvyApplication.h" #include "IvySynchroWnd.h" - +#include "IvyBinding.h" #define DEFAULT_ADDR "127.255.255.255" #define SEPARATOR ":" @@ -62,8 +62,7 @@ Ivy::Ivy(const char* name, const char * ready, IvyApplicationCallback *callback, IvySynchronousCallback::m_synchro = new IvySynchroWnd(); ready_message = ready; ApplicationName = name; - messages_classes_count = 0; - messages_classes = NULL; + binding_callback = NULL; application_callback = synchronous ? new IvySynchronousApplicationCallback(callback) : callback; direct_callback = NULL; @@ -364,22 +363,6 @@ void Ivy::SendDirectMsg(IvyApplication * app, int id, const char *message) app->SendMsg( IvyApplication::DirectMsg, id, message ); } -bool Ivy::CheckRegexp(const char * exp) -{ - /* accepte tout par default */ - int i; - bool regexp_ok = true; - if ( *exp =='^' && messages_classes_count !=0 ) - { - regexp_ok = false; - for ( i = 0 ; i < messages_classes_count; i++ ) - { - if (strncmp( messages_classes[i], exp+1, strlen( messages_classes[i] )) == 0) - return 1; - } - } - return regexp_ok; -} void Ivy::SetBindCallback( IvyBindingCallback* bind_callback ) { binding_callback = synchronous ? new IvySynchronousBindingCallback(bind_callback) : bind_callback; @@ -387,8 +370,7 @@ void Ivy::SetBindCallback( IvyBindingCallback* bind_callback ) void Ivy::SetFilter(int argc, const char **argv ) { - messages_classes_count = argc; - messages_classes = argv; + IvyBinding::SetFilter(argc, argv ); } bool Ivy::CheckConnected(IvyApplication * app) -- cgit v1.1 From fd7e142c90b804b21c86e8905922897f7f2ec4c5 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:30 +0000 Subject: Utilisateur : Fcolin Date : 2/06/06 Heure : 17:00 Archivé dans $/Bus/Ivy Commentaire: correction pb signe dans applicationUniqueID (vss 27) --- Ivy/Ivy.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 60ba574..d4c6056 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -82,10 +82,10 @@ Ivy::Ivy(const char* name, const char * ready, IvyApplicationCallback *callback, const char *Ivy::GenApplicationUniqueIdentifier() { static char appid[2048]; - long curtime; + unsigned long curtime; curtime = GetTickCount(); srand( curtime ); - sprintf(appid,"%d:%ld:%d",rand(),curtime,applicationPort); + sprintf(appid,"%d:%lu:%d",rand(),curtime,applicationPort); return appid; } -- cgit v1.1 From 19723f6393be5d66a750ce9a21ca4e4dba264cac Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:32 +0000 Subject: Utilisateur : Fcolin Date : 22/09/06 Heure : 14:54 Archivé dans $/Bus/Ivy Commentaire: (vss 28) --- Ivy/Ivy.cxx | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 52 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index d4c6056..0a09c91 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -10,6 +10,7 @@ #include "IvyApplication.h" #include "IvySynchroWnd.h" #include "IvyBinding.h" +#include "intervalRegexp.h" #define DEFAULT_ADDR "127.255.255.255" #define SEPARATOR ":" @@ -149,7 +150,10 @@ void Ivy::stop() } int Ivy::BindMsg(const char *regexp, IvyMessageCallback *cb) { - regexp_out.push_back( regexp ); + char buffer[8192]; + + SubstituteInterval( regexp, buffer, sizeof( buffer ) ); + regexp_out.push_back( buffer ); callbacks.push_back( synchronous ? new IvySynchronousMessageCallback(cb) : cb ); /* send to already connected */ @@ -157,20 +161,23 @@ int Ivy::BindMsg(const char *regexp, IvyMessageCallback *cb) for ( iter = applications.begin() ; iter != applications.end() ; ++iter ) { IvyApplication *app = *iter; - app->SendMsg(IvyApplication::AddRegexp, regexp_id, regexp ); + app->SendMsg(IvyApplication::AddRegexp, regexp_id, buffer ); } return regexp_id++; } int Ivy::BindMsg( IvyMessageCallback *cb, const char *regexp, ... ) { char buffer[4096]; + char buffer2[8192]; va_list args; va_start( args, regexp ); /* Initialize variable arguments. */ _vsnprintf_s( buffer, sizeof(buffer), sizeof(buffer)-1, regexp, args ); va_end( args); - regexp_out.push_back( regexp ); + SubstituteInterval( buffer, buffer2, sizeof( buffer2 ) ); + + regexp_out.push_back( buffer2 ); callbacks.push_back( synchronous ? new IvySynchronousMessageCallback(cb) : cb ); /* send to already connected */ @@ -178,7 +185,7 @@ int Ivy::BindMsg( IvyMessageCallback *cb, const char *regexp, ... ) for ( iter = applications.begin() ; iter != applications.end() ; ++iter ) { IvyApplication *app = *iter; - app->SendMsg(IvyApplication::AddRegexp, regexp_id, buffer ); + app->SendMsg(IvyApplication::AddRegexp, regexp_id, buffer2 ); } return regexp_id++; } @@ -387,3 +394,44 @@ bool Ivy::CheckConnected(IvyApplication * app) } return false; } +void Ivy::SubstituteInterval (const char *src, char *dst, size_t dst_len) +{ +// #ifdef INTERVALREGEXP + + // pas de traitement couteux s'il n'y a rien à interpoler + if (strstr (src, "(?I") == NULL) { + return; + } else { + char *curPos; + char *itvPos; + char *dstPos = dst; + + curPos = (char *)src; + while ((itvPos = strstr (curPos, "(?I")) != NULL) { + // copie depuis la position courante jusqu'à l'intervalle + int lenCp, min,max; + char withDecimal; + lenCp = itvPos-curPos; + memcpy ( dstPos, curPos, lenCp); + curPos=itvPos; + dstPos += lenCp; + + // extraction des paramètres de l'intervalle + sscanf (itvPos, "(?I%d#%d%c", &min, &max, &withDecimal); + + // printf ("DBG> substituteInterval min=%d max=%d withDecimal=%d\n", + // min, max, (withDecimal != 'i')); + + // generation et copie de l'intervalle + regexpGen (dstPos, dst_len-(dstPos-dst), min, max, (withDecimal != 'i')); + dstPos = dst + strlen (dst); + + // consommation des caractères décrivant intervalle dans la chaine source + curPos = strstr (curPos, ")"); + curPos++; + } + strncat (dstPos, curPos, dst_len-(dstPos-dst)); + } +// #endif +} + -- cgit v1.1 From 0bae5197999f5ed9e52bf3b94acb9e3f107a20e6 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:34 +0000 Subject: Utilisateur : Fcolin Date : 22/09/06 Heure : 18:11 Archivé dans $/Bus/Ivy Commentaire: ajout intervalRegexp (vss 29) --- Ivy/Ivy.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.cxx b/Ivy/Ivy.cxx index 0a09c91..4564c6f 100644 --- a/Ivy/Ivy.cxx +++ b/Ivy/Ivy.cxx @@ -396,10 +396,10 @@ bool Ivy::CheckConnected(IvyApplication * app) } void Ivy::SubstituteInterval (const char *src, char *dst, size_t dst_len) { -// #ifdef INTERVALREGEXP // pas de traitement couteux s'il n'y a rien à interpoler if (strstr (src, "(?I") == NULL) { + strcpy (dst,src); return; } else { char *curPos; @@ -432,6 +432,6 @@ void Ivy::SubstituteInterval (const char *src, char *dst, size_t dst_len) } strncat (dstPos, curPos, dst_len-(dstPos-dst)); } -// #endif + } -- cgit v1.1 From 749bdfcc57e0b35e35cc8a0ac32178c5155d67b0 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:42 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/Ivy.dsp | 183 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 183 insertions(+) create mode 100644 Ivy/Ivy.dsp (limited to 'Ivy') diff --git a/Ivy/Ivy.dsp b/Ivy/Ivy.dsp new file mode 100644 index 0000000..7fc2af4 --- /dev/null +++ b/Ivy/Ivy.dsp @@ -0,0 +1,183 @@ +# Microsoft Developer Studio Project File - Name="Ivy" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102 + +CFG=Ivy - Win32 Debug +!MESSAGE This is not a valid makefile. To build this project using NMAKE, +!MESSAGE use the Export Makefile command and run +!MESSAGE +!MESSAGE NMAKE /f "Ivy.mak". +!MESSAGE +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "Ivy.mak" CFG="Ivy - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "Ivy - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") +!MESSAGE "Ivy - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName ""$/Ivy", NBEAAAAA" +# PROP Scc_LocalPath "." +CPP=cl.exe +MTL=midl.exe +RSC=rc.exe + +!IF "$(CFG)" == "Ivy - Win32 Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "Release" +# PROP BASE Intermediate_Dir "Release" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "Release" +# PROP Intermediate_Dir "Release" +# PROP Target_Dir "" +# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /YX /FD /c +# ADD CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /YX /FD /c +# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x40c /d "NDEBUG" +# ADD RSC /l 0x40c /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 + +!ELSEIF "$(CFG)" == "Ivy - Win32 Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "Debug" +# PROP BASE Intermediate_Dir "Debug" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "Debug" +# PROP Intermediate_Dir "Debug" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /YX /FD /GZ /c +# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /Yu"stdafx.h" /FD /GZ /c +# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x40c /d "_DEBUG" +# ADD RSC /l 0x40c /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept +# ADD LINK32 ws2_32.lib user32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept + +!ENDIF + +# Begin Target + +# Name "Ivy - Win32 Release" +# Name "Ivy - Win32 Debug" +# Begin Group "Source Files" + +# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" +# Begin Source File + +SOURCE=.\BufferedSocket.cxx +# End Source File +# Begin Source File + +SOURCE=.\Ivy.cxx +# End Source File +# Begin Source File + +SOURCE=.\IvyApplication.cxx +# End Source File +# Begin Source File + +SOURCE=.\IvyDllMain.cpp +# End Source File +# Begin Source File + +SOURCE=.\IvySynchroWnd.cxx +# End Source File +# Begin Source File + +SOURCE=.\IvyWatcher.cxx +# End Source File +# Begin Source File + +SOURCE=.\Regexp.cxx +# End Source File +# Begin Source File + +SOURCE=.\StdAfx.cpp + +!IF "$(CFG)" == "Ivy - Win32 Release" + +!ELSEIF "$(CFG)" == "Ivy - Win32 Debug" + +# ADD CPP /Yc"stdafx.h" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\ThreadedSocket.cxx +# End Source File +# End Group +# Begin Group "Header Files" + +# PROP Default_Filter "h;hpp;hxx;hm;inl" +# Begin Source File + +SOURCE=.\BufferedSocket.h +# End Source File +# Begin Source File + +SOURCE=.\Ivy.h +# End Source File +# Begin Source File + +SOURCE=.\IvyApplication.h +# End Source File +# Begin Source File + +SOURCE=.\IvyCallback.h +# End Source File +# Begin Source File + +SOURCE=.\IvySynchroWnd.h +# End Source File +# Begin Source File + +SOURCE=.\IvyWatcher.h +# End Source File +# Begin Source File + +SOURCE=.\Regexp.h +# End Source File +# Begin Source File + +SOURCE=.\StdAfx.h +# End Source File +# Begin Source File + +SOURCE=.\ThreadedSocket.h +# End Source File +# End Group +# Begin Group "Resource Files" + +# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" +# End Group +# End Target +# End Project -- cgit v1.1 From b38a61af750db7bf581929e5fde47673b734b121 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:43 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:40 Archivé dans $/Ivy Commentaire: Init dll socket dans DLLMain (vss 2) --- Ivy/Ivy.dsp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.dsp b/Ivy/Ivy.dsp index 7fc2af4..56180d9 100644 --- a/Ivy/Ivy.dsp +++ b/Ivy/Ivy.dsp @@ -67,8 +67,8 @@ LINK32=link.exe # PROP Intermediate_Dir "Debug" # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" -# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /YX /FD /GZ /c -# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /Yu"stdafx.h" /FD /GZ /c +# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /YX /FD /GZ /c +# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /Yu"stdafx.h" /FD /GZ /c # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD BASE RSC /l 0x40c /d "_DEBUG" @@ -78,7 +78,7 @@ BSC32=bscmake.exe # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept -# ADD LINK32 ws2_32.lib user32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept +# ADD LINK32 ws2_32.lib user32.lib /nologo /dll /debug /machine:I386 /out:"d:\users\fcolin\Program Files\Debug\Ivy.dll" /pdbtype:sept !ENDIF -- cgit v1.1 From 4c3e81594dd3d471996614420e90a5a0bfd1eaa6 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:45 +0000 Subject: Utilisateur : Fcolin Date : 29/06/00 Heure : 15:59 Archivé dans $/Ivy Commentaire: Version multicast (vss 3) --- Ivy/Ivy.dsp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.dsp b/Ivy/Ivy.dsp index 56180d9..f94cce7 100644 --- a/Ivy/Ivy.dsp +++ b/Ivy/Ivy.dsp @@ -78,7 +78,7 @@ BSC32=bscmake.exe # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept -# ADD LINK32 ws2_32.lib user32.lib /nologo /dll /debug /machine:I386 /out:"d:\users\fcolin\Program Files\Debug\Ivy.dll" /pdbtype:sept +# ADD LINK32 wsock32.lib ws2_32.lib user32.lib /nologo /dll /debug /machine:I386 /out:"d:\users\fcolin\Program Files\Debug\Ivy.dll" /pdbtype:sept !ENDIF -- cgit v1.1 From 02058bb1dbce22c23334fe15489cb1cbd480a80c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:47 +0000 Subject: Utilisateur : Fcolin Date : 4/01/01 Heure : 15:36 Archivé dans $/Ivy (vss 4) --- Ivy/Ivy.dsp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.dsp b/Ivy/Ivy.dsp index f94cce7..81134f9 100644 --- a/Ivy/Ivy.dsp +++ b/Ivy/Ivy.dsp @@ -78,7 +78,7 @@ BSC32=bscmake.exe # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept -# ADD LINK32 wsock32.lib ws2_32.lib user32.lib /nologo /dll /debug /machine:I386 /out:"d:\users\fcolin\Program Files\Debug\Ivy.dll" /pdbtype:sept +# ADD LINK32 wsock32.lib ws2_32.lib user32.lib /nologo /dll /debug /machine:I386 /out:"c:\users\fcolin\Program Files\Debug\Ivy.dll" /pdbtype:sept !ENDIF -- cgit v1.1 From 5f49bec37b16a439cab14bcdb282a84218d6599e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:49 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 5) --- Ivy/Ivy.dsp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.dsp b/Ivy/Ivy.dsp index 81134f9..7f06599 100644 --- a/Ivy/Ivy.dsp +++ b/Ivy/Ivy.dsp @@ -68,7 +68,7 @@ LINK32=link.exe # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /YX /FD /GZ /c -# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /Yu"stdafx.h" /FD /GZ /c +# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "IVY_EXPORTS" /Yu"stdafx.h" /FD /GZ /c # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD BASE RSC /l 0x40c /d "_DEBUG" @@ -144,6 +144,10 @@ SOURCE=.\BufferedSocket.h # End Source File # Begin Source File +SOURCE=.\DataTypes.h +# End Source File +# Begin Source File + SOURCE=.\Ivy.h # End Source File # Begin Source File -- cgit v1.1 From ec949dd5fdbf59c2bdb40debdb8ff92722929814 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:51 +0000 Subject: Utilisateur : Fcolin Date : 23/05/01 Heure : 10:24 Archivé dans $/Ivy (vss 6) --- Ivy/Ivy.dsp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.dsp b/Ivy/Ivy.dsp index 7f06599..0d72efc 100644 --- a/Ivy/Ivy.dsp +++ b/Ivy/Ivy.dsp @@ -68,7 +68,7 @@ LINK32=link.exe # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /YX /FD /GZ /c -# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "IVY_EXPORTS" /Yu"stdafx.h" /FD /GZ /c +# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "IVY_EXPORTS" /D "NO_IVY_DEBUG" /Yu"stdafx.h" /FD /GZ /c # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD BASE RSC /l 0x40c /d "_DEBUG" -- cgit v1.1 From 75c086d9500f40c5a5b8f085f2fa4e7f74492839 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:53 +0000 Subject: Utilisateur : Fcolin Date : 17/07/01 Heure : 18:25 Archivé dans $/Ivy (vss 7) --- Ivy/Ivy.dsp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.dsp b/Ivy/Ivy.dsp index 0d72efc..137abf0 100644 --- a/Ivy/Ivy.dsp +++ b/Ivy/Ivy.dsp @@ -40,9 +40,10 @@ RSC=rc.exe # PROP Use_Debug_Libraries 0 # PROP Output_Dir "Release" # PROP Intermediate_Dir "Release" +# PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /YX /FD /c -# ADD CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /YX /FD /c +# ADD CPP /nologo /MDd /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /YX /FD /c # ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 # ADD BASE RSC /l 0x40c /d "NDEBUG" @@ -52,7 +53,7 @@ BSC32=bscmake.exe # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 -# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 +# ADD LINK32 wsock32.lib ws2_32.lib user32.lib /nologo /dll /machine:I386 !ELSEIF "$(CFG)" == "Ivy - Win32 Debug" @@ -68,7 +69,7 @@ LINK32=link.exe # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /YX /FD /GZ /c -# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "IVY_EXPORTS" /D "NO_IVY_DEBUG" /Yu"stdafx.h" /FD /GZ /c +# ADD CPP /nologo /MDd /W3 /Gm /Gi /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "IVY_EXPORTS" /D "NO_IVY_DEBUG" /Yu"stdafx.h" /FD /GZ /c # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD BASE RSC /l 0x40c /d "_DEBUG" @@ -78,7 +79,7 @@ BSC32=bscmake.exe # ADD BSC32 /nologo LINK32=link.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept -# ADD LINK32 wsock32.lib ws2_32.lib user32.lib /nologo /dll /debug /machine:I386 /out:"c:\users\fcolin\Program Files\Debug\Ivy.dll" /pdbtype:sept +# ADD LINK32 wsock32.lib user32.lib /nologo /dll /profile /debug /machine:I386 /out:"c:\users\fcolin\Program Files\Debug\Ivy.dll" !ENDIF -- cgit v1.1 From b6c55ededcfaa1e5fb4bf75c6261b4a2e3d687ca Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:55 +0000 Subject: Utilisateur : Fcolin Date : 19/07/01 Heure : 19:21 Archivé dans $/Ivy (vss 8) --- Ivy/Ivy.dsp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.dsp b/Ivy/Ivy.dsp index 137abf0..015ae11 100644 --- a/Ivy/Ivy.dsp +++ b/Ivy/Ivy.dsp @@ -69,7 +69,7 @@ LINK32=link.exe # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IVY_EXPORTS" /YX /FD /GZ /c -# ADD CPP /nologo /MDd /W3 /Gm /Gi /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "IVY_EXPORTS" /D "NO_IVY_DEBUG" /Yu"stdafx.h" /FD /GZ /c +# ADD CPP /nologo /MDd /W3 /Gm /Gi /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "IVY_EXPORTS" /D "NO_IVY_DEBUG" /FR /Yu"stdafx.h" /FD /GZ /c # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD BASE RSC /l 0x40c /d "_DEBUG" -- cgit v1.1 From dd63aa2213ef0a19d446bdaaaf37de3f0bcad264 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:57 +0000 Subject: Utilisateur : Fcolin Date : 25/10/01 Heure : 18:39 Archivé dans $/Ivy (vss 9) --- Ivy/Ivy.dsp | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.dsp b/Ivy/Ivy.dsp index 015ae11..d36f170 100644 --- a/Ivy/Ivy.dsp +++ b/Ivy/Ivy.dsp @@ -25,7 +25,7 @@ CFG=Ivy - Win32 Debug # PROP AllowPerConfigDependencies 0 # PROP Scc_ProjName ""$/Ivy", NBEAAAAA" # PROP Scc_LocalPath "." -CPP=cl.exe +CPP=xicl6.exe MTL=midl.exe RSC=rc.exe @@ -51,7 +51,7 @@ RSC=rc.exe BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo -LINK32=link.exe +LINK32=xilink6.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 # ADD LINK32 wsock32.lib ws2_32.lib user32.lib /nologo /dll /machine:I386 @@ -77,7 +77,7 @@ LINK32=link.exe BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo -LINK32=link.exe +LINK32=xilink6.exe # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept # ADD LINK32 wsock32.lib user32.lib /nologo /dll /profile /debug /machine:I386 /out:"c:\users\fcolin\Program Files\Debug\Ivy.dll" @@ -104,6 +104,10 @@ SOURCE=.\IvyApplication.cxx # End Source File # Begin Source File +SOURCE=.\IvyCbindings.cxx +# End Source File +# Begin Source File + SOURCE=.\IvyDllMain.cpp # End Source File # Begin Source File @@ -161,6 +165,10 @@ SOURCE=.\IvyCallback.h # End Source File # Begin Source File +SOURCE=.\IvyCbindings.h +# End Source File +# Begin Source File + SOURCE=.\IvySynchroWnd.h # End Source File # Begin Source File -- cgit v1.1 From 3a4b32280456fd880bbd2282171f7087a9137314 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:56:59 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/Ivy.h | 97 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 Ivy/Ivy.h (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h new file mode 100644 index 0000000..4fa1859 --- /dev/null +++ b/Ivy/Ivy.h @@ -0,0 +1,97 @@ +// Ivy.h: interface for the Ivy class. +// +////////////////////////////////////////////////////////////////////// + +#if !defined(AFX_BUS_H__F7F08FE9_E653_11D0_AE3E_080009F92591__INCLUDED_) +#define AFX_BUS_H__F7F08FE9_E653_11D0_AE3E_080009F92591__INCLUDED_ + +#if _MSC_VER >= 1000 +#pragma once +#endif // _MSC_VER >= 1000 +#ifdef WIN32 +#ifdef IVY_EXPORTS +class _declspec(dllexport) IvyWatcher; +class _declspec(dllexport) IvyApplication; +class _declspec(dllexport) Ivy; +#else +#pragma comment(lib,"Ivy.LIB" ) +class _declspec(dllimport) IvyWatcher; +class _declspec(dllimport) IvyApplication; +class _declspec(dllimport) Ivy; +#endif +#endif + +#include "stdafx.h" + +#include "IvyCallback.h" + +class IvyWatcher; + +class IvyApplication; + +class Ivy +{ +private: + + UINT applicationPort; + void SendSubscriptions(IvyApplication *app); + +public: + void AddApplication( IvyApplication *app ); + void RemoveApplication( IvyApplication *app); + + BOOL CheckConnected( IvyApplication *app ); + BOOL CheckRegexp( const char *exp ); + void CallApplicationConnectedCallback( IvyApplication *app ); + void CallApplicationDisconnectedCallback( IvyApplication *app ); + BOOL CallDieCallback( IvyApplication *app, int id, const char *arg ); + void CallDirectMessageCallback( IvyApplication *app, int id, const char *arg ); + void CallMessageCallback( IvyApplication *app, int id, int argc, const char **argv ); + + +public: + + void Classes( int argc, const char **argv ); + + void SendDirectMsg( IvyApplication *app, int id, const char *message); + void BindDirectMsg( IvyDirectMessageCallback *callback ); + int SendMsg( const char *message ); + + const char *GetDomain(const char *domainlist); + UINT GetApplicationPort(); + int BindMsg( const char *regexp, IvyMessageCallback *cb ); + void UnbindMsg( int id ); + Ivy( const char *name, const char* ready, IvyApplicationCallback *callback, bool Synchronous = true ); + void start(const char *domain); + void stop(); + virtual ~Ivy(); + + /* message a emettre sur connection nouvelle application */ + string ready_message; + +protected: + bool synchronous; // use Window Shink to made CB mono thread like + IvyApplication * server; + IvyWatcher * watcher; + IvyDieCallback *die_callback; + IvyDirectMessageCallback *direct_callback; + IvyApplicationCallback *application_callback; + /* list des adresses de broadcast */ + string domain; + /* nom de l'appliction */ + string appname; + /* liste des clients connectes */ + CRITICAL_SECTION m_application_cs; + std::vector applications; + + /* liste des souscriptions locale a emettre aux autres applications */ + std::vector regexp_out; + /* liste des callbacks a appeler */ + std::vector< IvyMessageCallback* > callbacks; + /* classes de messages emis par l'application utilise pour le filtrage */ + int messages_classes_count; + const char **messages_classes; + +}; + +#endif // !defined(AFX_BUS_H__F7F08FE9_E653_11D0_AE3E_080009F92591__INCLUDED_) -- cgit v1.1 From 38ea33b22d7de3fe79da5ee0b539f5eef251516f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:01 +0000 Subject: Utilisateur : Fcolin Date : 20/07/00 Heure : 10:57 Archivé dans $/Ivy (vss 2) --- Ivy/Ivy.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 4fa1859..b0a175e 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -82,7 +82,8 @@ protected: string appname; /* liste des clients connectes */ CRITICAL_SECTION m_application_cs; - std::vector applications; + typedef std::list IvyApplicationList; + IvyApplicationList applications; /* liste des souscriptions locale a emettre aux autres applications */ std::vector regexp_out; -- cgit v1.1 From 30647835ffd705bf9915c2990654d731946b9c24 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:03 +0000 Subject: Utilisateur : Fcolin Date : 23/01/01 Heure : 13:12 Archivé dans $/Ivy Commentaire: remove 'using name space std;' (vss 3) --- Ivy/Ivy.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index b0a175e..451a6c7 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -67,7 +67,7 @@ public: virtual ~Ivy(); /* message a emettre sur connection nouvelle application */ - string ready_message; + String ready_message; protected: bool synchronous; // use Window Shink to made CB mono thread like @@ -77,16 +77,16 @@ protected: IvyDirectMessageCallback *direct_callback; IvyApplicationCallback *application_callback; /* list des adresses de broadcast */ - string domain; + String domain; /* nom de l'appliction */ - string appname; + String appname; /* liste des clients connectes */ CRITICAL_SECTION m_application_cs; typedef std::list IvyApplicationList; IvyApplicationList applications; /* liste des souscriptions locale a emettre aux autres applications */ - std::vector regexp_out; + std::vector regexp_out; /* liste des callbacks a appeler */ std::vector< IvyMessageCallback* > callbacks; /* classes de messages emis par l'application utilise pour le filtrage */ -- cgit v1.1 From 214894a6685c10e3a0576e3f2acef2977f3d1b7d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:05 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 4) --- Ivy/Ivy.h | 29 ++++++++++++----------------- 1 file changed, 12 insertions(+), 17 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 451a6c7..e2258b7 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -2,12 +2,9 @@ // ////////////////////////////////////////////////////////////////////// -#if !defined(AFX_BUS_H__F7F08FE9_E653_11D0_AE3E_080009F92591__INCLUDED_) -#define AFX_BUS_H__F7F08FE9_E653_11D0_AE3E_080009F92591__INCLUDED_ -#if _MSC_VER >= 1000 #pragma once -#endif // _MSC_VER >= 1000 + #ifdef WIN32 #ifdef IVY_EXPORTS class _declspec(dllexport) IvyWatcher; @@ -33,18 +30,18 @@ class Ivy { private: - UINT applicationPort; + unsigned short applicationPort; void SendSubscriptions(IvyApplication *app); public: void AddApplication( IvyApplication *app ); void RemoveApplication( IvyApplication *app); - BOOL CheckConnected( IvyApplication *app ); - BOOL CheckRegexp( const char *exp ); + bool CheckConnected( IvyApplication *app ); + bool CheckRegexp( const char *exp ); void CallApplicationConnectedCallback( IvyApplication *app ); void CallApplicationDisconnectedCallback( IvyApplication *app ); - BOOL CallDieCallback( IvyApplication *app, int id, const char *arg ); + bool CallDieCallback( IvyApplication *app, int id, const char *arg ); void CallDirectMessageCallback( IvyApplication *app, int id, const char *arg ); void CallMessageCallback( IvyApplication *app, int id, int argc, const char **argv ); @@ -58,7 +55,7 @@ public: int SendMsg( const char *message ); const char *GetDomain(const char *domainlist); - UINT GetApplicationPort(); + unsigned short GetApplicationPort(); int BindMsg( const char *regexp, IvyMessageCallback *cb ); void UnbindMsg( int id ); Ivy( const char *name, const char* ready, IvyApplicationCallback *callback, bool Synchronous = true ); @@ -67,7 +64,7 @@ public: virtual ~Ivy(); /* message a emettre sur connection nouvelle application */ - String ready_message; + string ready_message; protected: bool synchronous; // use Window Shink to made CB mono thread like @@ -77,22 +74,20 @@ protected: IvyDirectMessageCallback *direct_callback; IvyApplicationCallback *application_callback; /* list des adresses de broadcast */ - String domain; + string domain; /* nom de l'appliction */ - String appname; + string appname; /* liste des clients connectes */ CRITICAL_SECTION m_application_cs; - typedef std::list IvyApplicationList; + typedef list IvyApplicationList; IvyApplicationList applications; /* liste des souscriptions locale a emettre aux autres applications */ - std::vector regexp_out; + vector regexp_out; /* liste des callbacks a appeler */ - std::vector< IvyMessageCallback* > callbacks; + vector< IvyMessageCallback* > callbacks; /* classes de messages emis par l'application utilise pour le filtrage */ int messages_classes_count; const char **messages_classes; }; - -#endif // !defined(AFX_BUS_H__F7F08FE9_E653_11D0_AE3E_080009F92591__INCLUDED_) -- cgit v1.1 From 71900ebe5eb5c5649f3a1743295a97c9edab4fca Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:07 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 5) --- Ivy/Ivy.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index e2258b7..da73f08 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -10,11 +10,15 @@ class _declspec(dllexport) IvyWatcher; class _declspec(dllexport) IvyApplication; class _declspec(dllexport) Ivy; +class _declspec(dllexport) CThreadedSocket; +class _declspec(dllexport) CBufferedSocket; #else #pragma comment(lib,"Ivy.LIB" ) class _declspec(dllimport) IvyWatcher; class _declspec(dllimport) IvyApplication; class _declspec(dllimport) Ivy; +class _declspec(dllimport) CThreadedSocket; +class _declspec(dllimport) CBufferedSocket; #endif #endif -- cgit v1.1 From de259aa0ec84e486e0c4e41b7b210061c4a469ad Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:09 +0000 Subject: Utilisateur : Fcolin Date : 18/10/01 Heure : 18:32 Archivé dans $/Ivy (vss 6) --- Ivy/Ivy.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index da73f08..77636ed 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -22,8 +22,6 @@ class _declspec(dllimport) CBufferedSocket; #endif #endif -#include "stdafx.h" - #include "IvyCallback.h" class IvyWatcher; -- cgit v1.1 From 5c51566c46abd63b37fea5f64c9b5b8ae5c5df31 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:11 +0000 Subject: Utilisateur : Fcolin Date : 25/10/01 Heure : 18:39 Archivé dans $/Ivy (vss 7) --- Ivy/Ivy.h | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 77636ed..02538d7 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -22,6 +22,27 @@ class _declspec(dllimport) CBufferedSocket; #endif #endif +#include + +#ifndef UNDER_CE +#define STL +#endif +#ifdef STL +#include +#include +#include + +using std::string; +using std::vector; +using std::list; +#else +#include "DataTypes.h" +#endif + +#pragma warning(disable: 4275) +#pragma warning(disable: 4251) +#pragma warning(disable: 4786) + #include "IvyCallback.h" class IvyWatcher; @@ -51,10 +72,11 @@ public: public: void Classes( int argc, const char **argv ); - + void SendDieMsg( IvyApplication *app ); + IvyApplication *GetApplication(const char *name); void SendDirectMsg( IvyApplication *app, int id, const char *message); void BindDirectMsg( IvyDirectMessageCallback *callback ); - int SendMsg( const char *message ); + int SendMsg( const char *message, ... ); const char *GetDomain(const char *domainlist); unsigned short GetApplicationPort(); -- cgit v1.1 From 068c8777dab6cae18e85f08d8d2425ffcfec0cf7 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:13 +0000 Subject: Utilisateur : Fcolin Date : 19/06/02 Heure : 15:14 Archivé dans $/Ivy (vss 8) --- Ivy/Ivy.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 02538d7..07e18fe 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -53,7 +53,7 @@ class Ivy { private: - unsigned short applicationPort; + unsigned int applicationPort; void SendSubscriptions(IvyApplication *app); public: @@ -79,7 +79,7 @@ public: int SendMsg( const char *message, ... ); const char *GetDomain(const char *domainlist); - unsigned short GetApplicationPort(); + unsigned int GetApplicationPort(); int BindMsg( const char *regexp, IvyMessageCallback *cb ); void UnbindMsg( int id ); Ivy( const char *name, const char* ready, IvyApplicationCallback *callback, bool Synchronous = true ); -- cgit v1.1 From c20e4834742ba86360be15092e34d34845083073 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:15 +0000 Subject: Utilisateur : Fcolin Date : 6/01/03 Heure : 14:47 Archivé dans $/Bus/Ivy Commentaire: (vss 9) --- Ivy/Ivy.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 07e18fe..c861fae 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -52,7 +52,7 @@ class IvyApplication; class Ivy { private: - + int regexp_id; unsigned int applicationPort; void SendSubscriptions(IvyApplication *app); @@ -81,6 +81,7 @@ public: const char *GetDomain(const char *domainlist); unsigned int GetApplicationPort(); int BindMsg( const char *regexp, IvyMessageCallback *cb ); + int BindMsg( IvyMessageCallback *cb, const char *regexp, ... ); void UnbindMsg( int id ); Ivy( const char *name, const char* ready, IvyApplicationCallback *callback, bool Synchronous = true ); void start(const char *domain); -- cgit v1.1 From 239cf6df4b6d30950869b5ecefaeaaacc3eda91b Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:17 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:45 Archivé dans $/Bus/Ivy Commentaire: (vss 10) --- Ivy/Ivy.h | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index c861fae..185f93d 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -24,20 +24,7 @@ class _declspec(dllimport) CBufferedSocket; #include -#ifndef UNDER_CE -#define STL -#endif -#ifdef STL -#include -#include -#include - -using std::string; -using std::vector; -using std::list; -#else #include "DataTypes.h" -#endif #pragma warning(disable: 4275) #pragma warning(disable: 4251) -- cgit v1.1 From bb7e4c76744e4b9684e95757eb58fd6c06560fcb Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:19 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 11) --- Ivy/Ivy.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 185f93d..7c6b523 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -76,7 +76,7 @@ public: virtual ~Ivy(); /* message a emettre sur connection nouvelle application */ - string ready_message; + ivy::string ready_message; protected: bool synchronous; // use Window Shink to made CB mono thread like @@ -86,18 +86,18 @@ protected: IvyDirectMessageCallback *direct_callback; IvyApplicationCallback *application_callback; /* list des adresses de broadcast */ - string domain; + ivy::string domain; /* nom de l'appliction */ - string appname; + ivy::string appname; /* liste des clients connectes */ CRITICAL_SECTION m_application_cs; - typedef list IvyApplicationList; + typedef ivy::list IvyApplicationList; IvyApplicationList applications; /* liste des souscriptions locale a emettre aux autres applications */ - vector regexp_out; + ivy::vector regexp_out; /* liste des callbacks a appeler */ - vector< IvyMessageCallback* > callbacks; + ivy::vector< IvyMessageCallback* > callbacks; /* classes de messages emis par l'application utilise pour le filtrage */ int messages_classes_count; const char **messages_classes; -- cgit v1.1 From bac78b00bd3f02e949ffa370fb2ae18641c32b23 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:21 +0000 Subject: Utilisateur : Fcolin Date : 16/11/05 Heure : 9:54 Archivé dans $/Bus/Ivy Commentaire: 64 bits ports (vss 12) --- Ivy/Ivy.h | 4 ---- 1 file changed, 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 7c6b523..fea2a93 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -26,10 +26,6 @@ class _declspec(dllimport) CBufferedSocket; #include "DataTypes.h" -#pragma warning(disable: 4275) -#pragma warning(disable: 4251) -#pragma warning(disable: 4786) - #include "IvyCallback.h" class IvyWatcher; -- cgit v1.1 From 1e1ff4438b0ccea93ccf5a746ff6c1fd8a3a4666 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:23 +0000 Subject: Utilisateur : Fcolin Date : 17/11/05 Heure : 15:08 Archivé dans $/Bus/Ivy Commentaire: nice Bug in nextArg not reentrant routine due to static variable (vss 13) --- Ivy/Ivy.h | 52 +++++++++++++++++++++++++++------------------------- 1 file changed, 27 insertions(+), 25 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index fea2a93..7536f32 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -28,18 +28,41 @@ class _declspec(dllimport) CBufferedSocket; #include "IvyCallback.h" -class IvyWatcher; - -class IvyApplication; class Ivy { + friend class IvyWatcher; + + friend class IvyApplication; + private: int regexp_id; unsigned int applicationPort; void SendSubscriptions(IvyApplication *app); + bool synchronous; // use Window Shink to made CB mono thread like + IvyApplication * server; + IvyWatcher * watcher; + IvyDieCallback *die_callback; + IvyDirectMessageCallback *direct_callback; + IvyApplicationCallback *application_callback; + /* list des adresses de broadcast */ + ivy::string domain; + /* nom de l'appliction */ + ivy::string appname; + /* liste des clients connectes */ + CRITICAL_SECTION m_application_cs; + typedef ivy::list IvyApplicationList; + IvyApplicationList applications; -public: + /* liste des souscriptions locale a emettre aux autres applications */ + ivy::vector regexp_out; + /* liste des callbacks a appeler */ + ivy::vector< IvyMessageCallback* > callbacks; + /* classes de messages emis par l'application utilise pour le filtrage */ + int messages_classes_count; + const char **messages_classes; + +protected: void AddApplication( IvyApplication *app ); void RemoveApplication( IvyApplication *app); @@ -75,27 +98,6 @@ public: ivy::string ready_message; protected: - bool synchronous; // use Window Shink to made CB mono thread like - IvyApplication * server; - IvyWatcher * watcher; - IvyDieCallback *die_callback; - IvyDirectMessageCallback *direct_callback; - IvyApplicationCallback *application_callback; - /* list des adresses de broadcast */ - ivy::string domain; - /* nom de l'appliction */ - ivy::string appname; - /* liste des clients connectes */ - CRITICAL_SECTION m_application_cs; - typedef ivy::list IvyApplicationList; - IvyApplicationList applications; - /* liste des souscriptions locale a emettre aux autres applications */ - ivy::vector regexp_out; - /* liste des callbacks a appeler */ - ivy::vector< IvyMessageCallback* > callbacks; - /* classes de messages emis par l'application utilise pour le filtrage */ - int messages_classes_count; - const char **messages_classes; }; -- cgit v1.1 From 8760f54d8e7bec49438691895c88278480cf236d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:25 +0000 Subject: Utilisateur : Fcolin Date : 18/11/05 Heure : 11:46 Archivé dans $/Bus/Ivy Commentaire: repassage a la STL et correction bug multithread (vss 14) --- Ivy/Ivy.h | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 7536f32..38527ea 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -22,10 +22,20 @@ class _declspec(dllimport) CBufferedSocket; #endif #endif -#include +#ifdef IVY_USE_OWN_DATATYPES #include "DataTypes.h" +#else + +#include +#include +#include + +namespace ivy = std; + +#endif + #include "IvyCallback.h" -- cgit v1.1 From edb7e6c16b0825f319619b9a308e97509447a9e0 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:27 +0000 Subject: Utilisateur : Fcolin Date : 29/11/05 Heure : 18:47 Archivé dans $/Bus/Ivy Commentaire: (vss 15) --- Ivy/Ivy.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 38527ea..806c205 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -107,7 +107,5 @@ public: /* message a emettre sur connection nouvelle application */ ivy::string ready_message; -protected: - }; -- cgit v1.1 From f00e0cfa7fe02afa232ee5d4f3fd634e9ea78c2e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:29 +0000 Subject: Utilisateur : Fcolin Date : 23/05/06 Heure : 18:18 Archivé dans $/Bus/Ivy Commentaire: Modification protocol UDP (vss 16) --- Ivy/Ivy.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 806c205..ddbc752 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -58,7 +58,9 @@ private: /* list des adresses de broadcast */ ivy::string domain; /* nom de l'appliction */ - ivy::string appname; + ivy::string ApplicationName; + /* Aplication Unique ID */ + ivy::string ApplicationID; /* liste des clients connectes */ CRITICAL_SECTION m_application_cs; typedef ivy::list IvyApplicationList; @@ -84,7 +86,7 @@ protected: void CallDirectMessageCallback( IvyApplication *app, int id, const char *arg ); void CallMessageCallback( IvyApplication *app, int id, int argc, const char **argv ); - + const char *GenApplicationUniqueIdentifier(); public: void Classes( int argc, const char **argv ); -- cgit v1.1 From 1d992982b8385d757a9a9cce4f20077b70bff108 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:31 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 10:14 Archivé dans $/Bus/Ivy Commentaire: ajout Binding Callback et SetFilter (vss 17) --- Ivy/Ivy.h | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index ddbc752..08977cd 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -55,6 +55,7 @@ private: IvyDieCallback *die_callback; IvyDirectMessageCallback *direct_callback; IvyApplicationCallback *application_callback; + IvyBindingCallback *binding_callback; /* list des adresses de broadcast */ ivy::string domain; /* nom de l'appliction */ @@ -82,14 +83,18 @@ protected: bool CheckRegexp( const char *exp ); void CallApplicationConnectedCallback( IvyApplication *app ); void CallApplicationDisconnectedCallback( IvyApplication *app ); + void CallBindingAddCallback(IvyApplication * app, int id, const char * regexp); + void CallBindingRemoveCallback(IvyApplication * app, int id, const char * regexp); + void CallBindingFilterCallback(IvyApplication * app, int id, const char * regexp); bool CallDieCallback( IvyApplication *app, int id, const char *arg ); void CallDirectMessageCallback( IvyApplication *app, int id, const char *arg ); void CallMessageCallback( IvyApplication *app, int id, int argc, const char **argv ); const char *GenApplicationUniqueIdentifier(); public: - - void Classes( int argc, const char **argv ); + + void SetBindCallback( IvyBindingCallback* bind_callback ); + void SetFilter( int argc, const char **argv ); void SendDieMsg( IvyApplication *app ); IvyApplication *GetApplication(const char *name); void SendDirectMsg( IvyApplication *app, int id, const char *message); -- cgit v1.1 From eb10d0ca0c53bffa9956cb182c662c1df4b5f9f4 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:33 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 15:54 Archivé dans $/Bus/Ivy Commentaire: Separation module de traitement regexp (vss 18) --- Ivy/Ivy.h | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 08977cd..ee55e22 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -71,16 +71,12 @@ private: ivy::vector regexp_out; /* liste des callbacks a appeler */ ivy::vector< IvyMessageCallback* > callbacks; - /* classes de messages emis par l'application utilise pour le filtrage */ - int messages_classes_count; - const char **messages_classes; - + protected: void AddApplication( IvyApplication *app ); void RemoveApplication( IvyApplication *app); bool CheckConnected( IvyApplication *app ); - bool CheckRegexp( const char *exp ); void CallApplicationConnectedCallback( IvyApplication *app ); void CallApplicationDisconnectedCallback( IvyApplication *app ); void CallBindingAddCallback(IvyApplication * app, int id, const char * regexp); -- cgit v1.1 From c09ff411bfd2401bf1e62ed457c2460ffa338f9e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:35 +0000 Subject: Utilisateur : Fcolin Date : 6/06/06 Heure : 16:43 Archivé dans $/Bus/Ivy Commentaire: (vss 19) --- Ivy/Ivy.h | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index ee55e22..fe204f7 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -31,6 +31,7 @@ class _declspec(dllimport) CBufferedSocket; #include #include #include +#include namespace ivy = std; -- cgit v1.1 From 1c9db09141be61792996e21ed2f534c6a1e8eb5e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:37 +0000 Subject: Utilisateur : Fcolin Date : 9/08/06 Heure : 16:02 Archivé dans $/Bus/Ivy Commentaire: (vss 20) --- Ivy/Ivy.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index fe204f7..9bf137b 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -88,6 +88,10 @@ protected: void CallMessageCallback( IvyApplication *app, int id, int argc, const char **argv ); const char *GenApplicationUniqueIdentifier(); + + /* message a emettre sur connection nouvelle application */ + ivy::string ready_message; + public: void SetBindCallback( IvyBindingCallback* bind_callback ); @@ -108,8 +112,6 @@ public: void stop(); virtual ~Ivy(); - /* message a emettre sur connection nouvelle application */ - ivy::string ready_message; }; -- cgit v1.1 From b990a6aff7b0ff2657f6acf9b63e5a691d3ef2d6 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:39 +0000 Subject: Utilisateur : Fcolin Date : 22/09/06 Heure : 14:54 Archivé dans $/Bus/Ivy Commentaire: (vss 21) --- Ivy/Ivy.h | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 9bf137b..78e87ca 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -74,6 +74,7 @@ private: ivy::vector< IvyMessageCallback* > callbacks; protected: + void SubstituteInterval (const char *src, char *dst, size_t dst_len); void AddApplication( IvyApplication *app ); void RemoveApplication( IvyApplication *app); -- cgit v1.1 From b357419b3ee411d032ea8a061a2764e52f4356e6 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:41 +0000 Subject: Utilisateur : Fcolin Date : 22/01/07 Heure : 13:56 Archivé dans $/Bus/Ivy Commentaire: pour eviter les Warning sur les lib standarts (vss 22) --- Ivy/Ivy.h | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/Ivy.h b/Ivy/Ivy.h index 78e87ca..cf90bdd 100644 --- a/Ivy/Ivy.h +++ b/Ivy/Ivy.h @@ -4,6 +4,7 @@ #pragma once +#pragma warning(disable: 4251) #ifdef WIN32 #ifdef IVY_EXPORTS -- cgit v1.1 From d96d8eede291a98b769d420fadda6fab5e746aa6 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:43 +0000 Subject: Utilisateur : Fcolin Date : 10/06/02 Heure : 11:34 Créé Commentaire: (vss 1) --- Ivy/Ivy.vcproj | 213 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 213 insertions(+) create mode 100644 Ivy/Ivy.vcproj (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj new file mode 100644 index 0000000..754d4c1 --- /dev/null +++ b/Ivy/Ivy.vcproj @@ -0,0 +1,213 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- cgit v1.1 From e8fc397b27e337273cdf722b543662f24a152d2f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:45 +0000 Subject: Utilisateur : Fcolin Date : 10/06/02 Heure : 15:53 Archivé dans $/Ivy Commentaire: (vss 2) --- Ivy/Ivy.vcproj | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 754d4c1..891b860 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,6 +3,7 @@ ProjectType="Visual C++" Version="7.00" Name="Ivy" + ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" SccProjectName=""$/Ivy", NBEAAAAA" SccAuxPath="" SccLocalPath="." -- cgit v1.1 From 71157dee388d3a95c82ca7c1d02d46bc349fa496 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:47 +0000 Subject: Utilisateur : Fcolin Date : 11/06/02 Heure : 18:34 Archivé dans $/Ivy Commentaire: (vss 3) --- Ivy/Ivy.vcproj | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 891b860..1af96da 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -47,7 +47,8 @@ SuppressStartupBanner="TRUE" GenerateDebugInformation="TRUE" ProgramDatabaseFile=".\Debug/Ivy.pdb" - ImportLibrary=".\Debug/Ivy.lib"/> + ImportLibrary=".\Debug/Ivy.lib" + TargetMachine="1"/> + CharacterSet="0"> + ImportLibrary=".\Debug/Ivy.lib"/> + CharacterSet="2"> -- cgit v1.1 From 6df69dcb52a2b0faa318840888c45b7e606decd3 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:57:57 +0000 Subject: Utilisateur : Fcolin Date : 3/10/02 Heure : 12:09 Archivé dans $/Bus/Ivy Commentaire: (vss 8) --- Ivy/Ivy.vcproj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 8de782b..b18939a 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -14,7 +14,7 @@ + CharacterSet="0"> + Name="VCPostBuildEventTool" + Description="Copying libraries, headers & dll's..." + CommandLine="copy "$(TargetDir)$(TargetName).dll" "C:\users\fcolin\Program Files\$(OutDir)" +copy "$(TargetDir)$(TargetName).lib" "C:\users\fcolin\Program Files\lib\$(OutDir)" +copy Ivy.h "C:\users\fcolin\Program Files\Include\" +copy IvyApplication.h "C:\users\fcolin\Program Files\Include\" +copy IvyCallback.h "C:\users\fcolin\Program Files\Include\" +copy BufferedSocket.h "C:\users\fcolin\Program Files\Include\" +copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\""/> + Name="VCPostBuildEventTool" + Description="Copying libraries, headers & dll's..." + CommandLine="copy "$(TargetDir)$(TargetName).dll" "C:\users\fcolin\Program Files\$(OutDir)" +copy "$(TargetDir)$(TargetName).lib" "C:\users\fcolin\Program Files\lib\$(OutDir)" +copy Ivy.h "C:\users\fcolin\Program Files\Include\" +copy IvyApplication.h "C:\users\fcolin\Program Files\Include\" +copy IvyCallback.h "C:\users\fcolin\Program Files\Include\" +copy BufferedSocket.h "C:\users\fcolin\Program Files\Include\" +copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\""/> -- cgit v1.1 From 72324c03ec0c0eeca61dce4a9e17a2c11c332339 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:09 +0000 Subject: Utilisateur : Fcolin Date : 16/12/02 Heure : 10:12 Archivé dans $/Bus/Ivy Commentaire: Nouvelle version sans GLUT (vss 14) --- Ivy/Ivy.vcproj | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 85b050f..22d8a2c 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -65,7 +65,8 @@ copy Ivy.h "C:\users\fcolin\Program Files\Include\" copy IvyApplication.h "C:\users\fcolin\Program Files\Include\" copy IvyCallback.h "C:\users\fcolin\Program Files\Include\" copy BufferedSocket.h "C:\users\fcolin\Program Files\Include\" -copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\""/> +copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\" +"/> Name="VCCLCompilerTool" AdditionalOptions="" InlineFunctionExpansion="1" - PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;IVY_EXPORTS" + PreprocessorDefinitions="WIN32;_WINDOWS;_USRDLL;IVY_EXPORTS" StringPooling="TRUE" RuntimeLibrary="2" EnableFunctionLevelLinking="TRUE" @@ -128,7 +129,8 @@ copy Ivy.h "C:\users\fcolin\Program Files\Include\" copy IvyApplication.h "C:\users\fcolin\Program Files\Include\" copy IvyCallback.h "C:\users\fcolin\Program Files\Include\" copy BufferedSocket.h "C:\users\fcolin\Program Files\Include\" -copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\""/> +copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\" +"/> + + + + + + + + + + + + + + + + + + + + + + + + -- cgit v1.1 From 02a99bfffab6cf5d1a5c64f8ed5c542772951c85 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:15 +0000 Subject: Utilisateur : Fcolin Date : 3/03/05 Heure : 14:02 Archivé dans $/Bus/Ivy Commentaire: Passage a la lib PCRE (vss 17) --- Ivy/Ivy.vcproj | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 87ef2ea..8fecdd9 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -24,7 +24,8 @@ Name="VCCLCompilerTool" AdditionalOptions="" Optimization="0" - PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;IVY_EXPORTS;NO_IVY_DEBUG" + AdditionalIncludeDirectories=""C:\Program Files\GnuWin32\include"" + PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;IVY_EXPORTS;NO_IVY_DEBUG;USE_PCRE" BasicRuntimeChecks="3" RuntimeLibrary="3" BufferSecurityCheck="TRUE" @@ -43,9 +44,10 @@ -- cgit v1.1 From 3d0d36aa152ce5b6aaac1bcc7ab540e7df74a358 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:17 +0000 Subject: Utilisateur : Fcolin Date : 3/03/05 Heure : 18:40 Archivé dans $/Bus/Ivy Commentaire: modif pour lecture dans le scenario de la config center et radius affiché (vss 18) --- Ivy/Ivy.vcproj | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 8fecdd9..1d888f6 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -25,7 +25,7 @@ AdditionalOptions="" Optimization="0" AdditionalIncludeDirectories=""C:\Program Files\GnuWin32\include"" - PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;IVY_EXPORTS;NO_IVY_DEBUG;USE_PCRE" + PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;IVY_EXPORTS;NO_IVY_DEBUG" BasicRuntimeChecks="3" RuntimeLibrary="3" BufferSecurityCheck="TRUE" @@ -100,6 +100,7 @@ copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\" Name="VCCLCompilerTool" AdditionalOptions="" InlineFunctionExpansion="1" + AdditionalIncludeDirectories=""C:\Program Files\GnuWin32\include"" PreprocessorDefinitions="WIN32;_WINDOWS;_USRDLL;IVY_EXPORTS" StringPooling="TRUE" RuntimeLibrary="2" @@ -116,9 +117,10 @@ copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\" + + + + + - - - - - @@ -299,6 +298,9 @@ copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\" RelativePath=".\IvyCbindings.h"> + + - - -- cgit v1.1 From af73ca15252b447b65c8bbd7d66685803d9470ff Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:21 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:51 Archivé dans $/Bus/Ivy Commentaire: (vss 20) --- Ivy/Ivy.vcproj | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 7943699..7f39b34 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -105,7 +105,8 @@ copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\" StringPooling="TRUE" RuntimeLibrary="2" EnableFunctionLevelLinking="TRUE" - UsePrecompiledHeader="2" + UsePrecompiledHeader="3" + PrecompiledHeaderThrough="IvyStdAfx.h" PrecompiledHeaderFile=".\Release/Ivy.pch" AssemblerListingLocation=".\Release/" ObjectFile=".\Release/" @@ -262,6 +263,12 @@ copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\" Name="VCCLCompilerTool" UsePrecompiledHeader="1"/> + + + @@ -274,6 +281,12 @@ copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\" + + + @@ -141,7 +142,7 @@ copy IvyApplication.h "C:\users\fcolin\Program Files\Include\" copy IvyCallback.h "C:\users\fcolin\Program Files\Include\" copy BufferedSocket.h "C:\users\fcolin\Program Files\Include\" copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\" -"/> +copy DataTypes.h "C:\users\fcolin\Program Files\Include\""/> @@ -142,7 +143,8 @@ copy IvyApplication.h "C:\users\fcolin\Program Files\Include\" copy IvyCallback.h "C:\users\fcolin\Program Files\Include\" copy BufferedSocket.h "C:\users\fcolin\Program Files\Include\" copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\" -copy DataTypes.h "C:\users\fcolin\Program Files\Include\""/> +copy DataTypes.h "C:\users\fcolin\Program Files\Include\" +"/> + SccProvider="MSSCCI:Microsoft Visual SourceSafe" + > + Name="Win32" + /> + + + + ATLMinimizesCRunTimeLibraryUsage="false" + > + + + + + + SuppressStartupBanner="true" + Detect64BitPortabilityProblems="true" + DebugInformationFormat="4" + /> + + + Name="VCPreLinkEventTool" + /> + SuppressStartupBanner="true" + AdditionalLibraryDirectories="" + GenerateDebugInformation="true" + /> + Name="VCALinkTool" + /> + + + + + + + CommandLine="rem copy "$(TargetDir)$(TargetName).dll" "C:\users\fcolin\Program Files\$(OutDir)" rem copy "$(TargetDir)$(TargetName).lib" "C:\users\fcolin\Program Files\lib\$(OutDir)" rem copy Ivy.h "C:\users\fcolin\Program Files\Include\" rem copy IvyApplication.h "C:\users\fcolin\Program Files\Include\" rem copy IvyCallback.h "C:\users\fcolin\Program Files\Include\" rem copy BufferedSocket.h "C:\users\fcolin\Program Files\Include\" rem copy ThreadedSocket.h "C:\users\fcolin\Program Files\Include\" rem copy DataTypes.h "C:\users\fcolin\Program Files\Include\" " + /> + + + + Name="VCCustomBuildTool" + /> + Name="VCXMLDataGeneratorTool" + /> + + + + + Culture="1036" + /> + + + + + Name="VCXDCMakeTool" + /> + Name="VCBscMakeTool" + /> + Name="VCFxCopTool" + /> + Name="VCAppVerifierTool" + /> + Name="VCWebDeploymentTool" + /> + + ATLMinimizesCRunTimeLibraryUsage="false" + CharacterSet="0" + > + + + + + - + SuppressStartupBanner="true" + /> + Name="VCManagedResourceCompilerTool" + /> + Culture="1036" + /> + Name="VCPreLinkEventTool" + /> + Name="VCLinkerTool" + AdditionalDependencies="wsock32.lib" + LinkIncremental="1" + SuppressStartupBanner="true" + AdditionalLibraryDirectories="" + /> + Name="VCALinkTool" + /> + Name="VCManifestTool" + /> + Name="VCXDCMakeTool" + /> + Name="VCBscMakeTool" + /> + Name="VCFxCopTool" + /> + Name="VCAppVerifierTool" + /> + Name="VCWebDeploymentTool" + /> + + ATLMinimizesCRunTimeLibraryUsage="false" + CharacterSet="0" + > + + + + + + SuppressStartupBanner="true" + Detect64BitPortabilityProblems="true" + /> + Name="VCManagedResourceCompilerTool" + /> - + Culture="1036" + /> + Name="VCPreLinkEventTool" + /> + Name="VCLinkerTool" + AdditionalDependencies="wsock32.lib" + LinkIncremental="1" + SuppressStartupBanner="true" + AdditionalLibraryDirectories="" + TargetMachine="17" + /> + Name="VCALinkTool" + /> + Name="VCManifestTool" + /> + Name="VCXDCMakeTool" + /> + Name="VCBscMakeTool" + /> + Name="VCFxCopTool" + /> + Name="VCAppVerifierTool" + /> + Name="VCWebDeploymentTool" + /> + + + Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" + > + RelativePath=".\BufferedSocket.cxx" + > + RelativePath=".\Ivy.cxx" + > + RelativePath=".\IvyApplication.cxx" + > + RelativePath=".\IvyCbindings.cxx" + > + RelativePath=".\IvyDllMain.cpp" + > + RelativePath=".\IvyStdAfx.cpp" + > + + + + + + + Name="Release|Win32" + > + UsePrecompiledHeader="1" + /> + Name="Release|x64" + > + UsePrecompiledHeader="1" + /> + RelativePath=".\IvySynchroWnd.cxx" + > + RelativePath=".\IvyWatcher.cxx" + > + RelativePath=".\Regexp.cxx" + > + RelativePath=".\ThreadedSocket.cxx" + > + + + + Name="Release|x64" + > + UsePrecompiledHeader="2" + /> + Filter="h;hpp;hxx;hm;inl" + > + RelativePath=".\BufferedSocket.h" + > + RelativePath=".\DataTypes.h" + > + RelativePath=".\Ivy.h" + > + RelativePath=".\IvyApplication.h" + > + RelativePath=".\IvyCallback.h" + > + RelativePath=".\IvyCbindings.h" + > + RelativePath=".\IvyStdAfx.h" + > + RelativePath=".\IvySynchroWnd.h" + > + RelativePath=".\IvyWatcher.h" + > + RelativePath=".\Regexp.h" + > + RelativePath=".\ThreadedSocket.h" + > + Filter="ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" + > -- cgit v1.1 From d2521edcc6464a5aeb023b524475f2575dc46843 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:31 +0000 Subject: Utilisateur : Fcolin Date : 18/11/05 Heure : 11:46 Archivé dans $/Bus/Ivy Commentaire: repassage a la STL et correction bug multithread (vss 25) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 93f8f8d..ea66f8c 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" + ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From 76c3c45a5a3a22e08656b16f93a92dc3a93ec12a Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:33 +0000 Subject: Utilisateur : Fcolin Date : 29/11/05 Heure : 18:47 Archivé dans $/Bus/Ivy Commentaire: (vss 26) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index ea66f8c..93f8f8d 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" + ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From 30a785964b4a79646dfe32d4988cd84f2fa6b5b0 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:35 +0000 Subject: Utilisateur : Fcolin Date : 2/12/05 Heure : 10:00 Archivé dans $/Bus/Ivy Commentaire: (vss 27) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 93f8f8d..ea66f8c 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" + ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From 454c814a3bcbe0c8e79f0a244f4af51e3a9a1797 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:37 +0000 Subject: Utilisateur : Fcolin Date : 14/12/05 Heure : 11:21 Archivé dans $/Bus/Ivy Commentaire: (vss 28) --- Ivy/Ivy.vcproj | 66 +++++++++++++++++++++++++++++----------------------------- 1 file changed, 33 insertions(+), 33 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index ea66f8c..fa055af 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" + ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." @@ -113,13 +113,14 @@ /> -- cgit v1.1 From aeaadb9a8cc3dd7acb08948d4e2343d11f1492ac Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:43 +0000 Subject: Utilisateur : Fcolin Date : 22/12/05 Heure : 10:09 Archivé dans $/Bus/Ivy Commentaire: (vss 31) --- Ivy/Ivy.vcproj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index be6a4f5..c7fe386 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{84E0039A-6721-4B18-9792-E9AE4274AC0E}" + ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." @@ -386,7 +386,7 @@ -- cgit v1.1 From 890b8afa8267b27ed79536168f892ecc45234fb1 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:45 +0000 Subject: Utilisateur : Fcolin Date : 20/01/06 Heure : 13:50 Archivé dans $/Bus/Ivy Commentaire: (vss 32) --- Ivy/Ivy.vcproj | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index c7fe386..b7e8c69 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" + ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." @@ -288,8 +288,8 @@ /> -- cgit v1.1 From 0b93291c3ee853954b55621ceda32d89d03a84dd Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:49 +0000 Subject: Utilisateur : Fcolin Date : 2/02/06 Heure : 10:48 Archivé dans $/Bus/Ivy Commentaire: (vss 34) --- Ivy/Ivy.vcproj | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 4a5fbd8..b0b97bc 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -511,6 +511,10 @@ > + + -- cgit v1.1 From 14adba27a2e8c42c58b6c76ddb04d9b4e7a7c382 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:51 +0000 Subject: Utilisateur : Fcolin Date : 28/03/06 Heure : 17:45 Archivé dans $/Bus/Ivy Commentaire: (vss 35) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index b0b97bc..cdfcb25 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" + ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From 22a7779802349afeb58bd688b675531c83b8bbbe Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:53 +0000 Subject: Utilisateur : Fcolin Date : 31/03/06 Heure : 17:46 Archivé dans $/Bus/Ivy Commentaire: (vss 36) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index cdfcb25..b0b97bc 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" + ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From 928a91c1c54ffbabcc831adbae246c0897bcbafe Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:58:55 +0000 Subject: Utilisateur : Fcolin Date : 11/04/06 Heure : 11:18 Archivé dans $/Bus/Ivy Commentaire: (vss 37) --- Ivy/Ivy.vcproj | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index b0b97bc..6f57927 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -190,6 +190,7 @@ /> - - -- cgit v1.1 From 515e62f9b5fe2b60611ee5e9526516197e0681a2 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:03 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 15:54 Archivé dans $/Bus/Ivy Commentaire: Separation module de traitement regexp (vss 41) --- Ivy/Ivy.vcproj | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 4816888..ce0f3c0 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -200,8 +200,7 @@ /> + + @@ -504,6 +507,10 @@ > + + -- cgit v1.1 From 516adcee82535508ac26947ec8de5862911d6e79 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:05 +0000 Subject: Utilisateur : Fcolin Date : 6/06/06 Heure : 16:43 Archivé dans $/Bus/Ivy Commentaire: (vss 42) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index ce0f3c0..7706147 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" + ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From 13a76681e88fefd44da4f4f31e754628523c787e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:07 +0000 Subject: Utilisateur : Fcolin Date : 6/07/06 Heure : 11:37 Archivé dans $/Bus/Ivy Commentaire: (vss 43) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 7706147..ce0f3c0 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" + ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From 4317e8dab3ba7c2c555c79e72e5cba33fc16fd04 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:09 +0000 Subject: Utilisateur : Fcolin Date : 1/08/06 Heure : 9:48 Archivé dans $/Bus/Ivy Commentaire: (vss 44) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index ce0f3c0..7706147 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" + ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From 63b944708b463f8d5cd83883d42f8c86d34119a5 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:11 +0000 Subject: Utilisateur : Fcolin Date : 2/08/06 Heure : 18:08 Archivé dans $/Bus/Ivy Commentaire: (vss 45) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 7706147..ce0f3c0 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" + ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From ca340719e77c6a7a7397bfcdcf46cffcb70fc9e7 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:13 +0000 Subject: Utilisateur : Fcolin Date : 9/08/06 Heure : 16:02 Archivé dans $/Bus/Ivy Commentaire: (vss 46) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index ce0f3c0..7706147 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" + ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From 4c86806e19bec37f9ef931af30cea67aba3b7882 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:15 +0000 Subject: Utilisateur : Fcolin Date : 11/08/06 Heure : 11:42 Archivé dans $/Bus/Ivy Commentaire: modif TRACE MUTEX (vss 47) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 7706147..ce0f3c0 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" + ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From 0229cc94684d7d0ae0f0959d472a8344927a9a65 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:17 +0000 Subject: Utilisateur : Fcolin Date : 22/09/06 Heure : 14:54 Archivé dans $/Bus/Ivy Commentaire: (vss 48) --- Ivy/Ivy.vcproj | 42 +++++++++++++++++++++++++++++++++++++++++- 1 file changed, 41 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index ce0f3c0..1a0c185 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" + ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." @@ -398,6 +398,42 @@ > + + + + + + + + + + + + + + @@ -499,6 +535,10 @@ > + + -- cgit v1.1 From 4f5aec6957094109e2c9a958a39cb8919b8e89dc Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:19 +0000 Subject: Utilisateur : Fcolin Date : 22/09/06 Heure : 18:11 Archivé dans $/Bus/Ivy Commentaire: ajout intervalRegexp (vss 49) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 1a0c185..f9e983a 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" + ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From ca900b0e1c1404ce20773565870e9ad128117618 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:21 +0000 Subject: Utilisateur : Fcolin Date : 10/11/06 Heure : 13:43 Archivé dans $/Bus/Ivy Commentaire: (vss 50) --- Ivy/Ivy.vcproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index f9e983a..1a0c185 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" + ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." -- cgit v1.1 From c22678b9ac993e1cd43ccb52eeab214007880776 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:23 +0000 Subject: Utilisateur : Fcolin Date : 20/11/06 Heure : 18:36 Archivé dans $/Bus/Ivy Commentaire: (vss 51) --- Ivy/Ivy.vcproj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 1a0c185..5d1ef01 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{9BD87B7A-517E-4900-B3EA-A358885CD876}" + ProjectGUID="{84E0039A-6721-4B18-9792-E9AE4274AC0E}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." @@ -385,7 +385,7 @@ -- cgit v1.1 From aef65fa5cab9d61efb9c7209c5d9e94b90dffba5 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:25 +0000 Subject: Utilisateur : Fcolin Date : 24/11/06 Heure : 12:47 Archivé dans $/Bus/Ivy Commentaire: (vss 52) --- Ivy/Ivy.vcproj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj b/Ivy/Ivy.vcproj index 5d1ef01..f9e983a 100644 --- a/Ivy/Ivy.vcproj +++ b/Ivy/Ivy.vcproj @@ -3,7 +3,7 @@ ProjectType="Visual C++" Version="8,00" Name="Ivy" - ProjectGUID="{84E0039A-6721-4B18-9792-E9AE4274AC0E}" + ProjectGUID="{9818D652-CC05-463E-880D-AFCA2C7BFABE}" RootNamespace="Ivy" SccProjectName=""$/Bus/Ivy", QPEAAAAA" SccLocalPath="." @@ -385,7 +385,7 @@ -- cgit v1.1 From f99d050c1f337f4cb0b7bf149797d6f072fb4444 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:27 +0000 Subject: Utilisateur : Fcolin Date : 10/06/02 Heure : 13:14 Créé Commentaire: (vss 1) --- Ivy/Ivy.vcproj.vspscc | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 Ivy/Ivy.vcproj.vspscc (limited to 'Ivy') diff --git a/Ivy/Ivy.vcproj.vspscc b/Ivy/Ivy.vcproj.vspscc new file mode 100644 index 0000000..794f014 --- /dev/null +++ b/Ivy/Ivy.vcproj.vspscc @@ -0,0 +1,10 @@ +"" +{ +"FILE_VERSION" = "9237" +"ENLISTMENT_CHOICE" = "NEVER" +"PROJECT_FILE_RELATIVE_PATH" = "" +"NUMBER_OF_EXCLUDED_FILES" = "0" +"ORIGINAL_PROJECT_FILE_PATH" = "" +"NUMBER_OF_NESTED_PROJECTS" = "0" +"SOURCE_CONTROL_SETTINGS_PROVIDER" = "PROJECT" +} -- cgit v1.1 From cb4acfaf1f4b6a1a1fe0ee4722592022893f1d2a Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:29 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/IvyApplication.cxx | 307 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 307 insertions(+) create mode 100644 Ivy/IvyApplication.cxx (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx new file mode 100644 index 0000000..26d0adf --- /dev/null +++ b/Ivy/IvyApplication.cxx @@ -0,0 +1,307 @@ +// IvyApplication.cpp : implementation file +// + +#include "stdafx.h" +//#include "libIvy.h" +#include "IvyApplication.h" +#include "Regexp.h" + +//#define DEBUG + +#define ARG_START "\002" +#define ARG_END "\003" + + +///////////////////////////////////////////////////////////////////////////// +// IvyApplication + +IvyApplication::IvyApplication(Ivy * bus) +{ + this->bus = bus; + remoteService = 0; /* unknown or unconnected application */ + appname = "Unknown"; + AppConnectedCallbackCalled = false; +} + +IvyApplication::~IvyApplication() +{ +// bus->RemoveApplication( this ); + for ( int i = 0; i < regexp_in.size(); i++) + delete regexp_in[i]; + regexp_in.clear(); + if ( m_hSocket != INVALID_SOCKET ) + Close(); +} + + +///////////////////////////////////////////////////////////////////////////// +// IvyApplication member functions + + +void IvyApplication::Create(const char* host, UINT & port) +{ + // Exception to catch + CBufferedSocket::Create(); + Connect(host, port); +} + + + +UINT IvyApplication::Create() +{ + string host; + UINT port; + CBufferedSocket::Create(); + // Max Listen Connexion + Listen( SOMAXCONN ); + GetSockName( host, port ); + TRACE(" TCP %s:%d\n", host.c_str(), port ); +#ifdef DEBUG + TRACE( "IvyApplication::Create server socket %d\n", m_hSocket ); +#endif + return port; +} + +void IvyApplication::OnReceive(char * line) +{ + int err,id; + int kind_of_msg = Bye; + Regexp *exp; + + + int argc = 0; + const char *argv[Regexp::NSUBEXP]; + char *arg; + +#ifdef DEBUG + TRACE("Receive %s\n",line); +#endif //DEBUG + + err = sscanf( line ,"%d %d", &kind_of_msg, &id); + arg = strstr( line , ARG_START ); + if ( (err != 2) || (arg == NULL) ) + { + TRACE("Quitting bad format %s\n", line); + SendMsg(Error, Error, "bad format request expected 'type id ...'"); +// bus->RemoveApplication( this ); + Close(); + return; + } + arg++; + switch( kind_of_msg ) + { + case Bye: + +#ifdef DEBUG + TRACE("Quitting %s\n", line); +#endif //DEBUG + +// bus->RemoveApplication( this ); + Close(); + break; + case Error: + +#ifdef DEBUG + TRACE("Receive error %d %s\n", id, arg); +#endif //DEBUG + + break; + case AddRegexp: + +#ifdef DEBUG + TRACE("Regexp id=%d exp='%s'\n", id, arg); +#endif //DEBUG + + if ( !bus->CheckRegexp( arg ) ) + { +#ifdef DEBUG + TRACE("Warning exp='%s' can't match removing from %s\n",arg,appname); +#endif //DEBUG + return; + } + exp = new Regexp( arg ); + if ( !exp->CompiledOK() ) + { + string regerr = exp->GetErrorString(); + string err; + err = "Error can't compile regexp '"+string(arg)+"' error "+regerr; + SendMsg( Error, Error, err.c_str() ); + TRACE("IvyApplication %s\n",err.c_str()); + return; + } + if ( id +1 < regexp_in.size() ) + regexp_in[ id ] = exp ; + else regexp_in.push_back( exp ); + break; + case DelRegexp: + +#ifdef DEBUG + TRACE("Regexp Delete id=%d\n", id); +#endif //DEBUG + if ( id < regexp_in.size() ) + { + exp = regexp_in[ id ]; + delete exp; + regexp_in[ id ] = NULL ; + } + break; + case StartRegexp: + +#ifdef DEBUG + TRACE("Regexp Start id=%d\n", id); +#endif //DEBUG + + appname = arg; + /* remote socket port */ + remoteService = id; + if ( bus->CheckConnected( this ) ) + { + TRACE("Quitting already connected %s\n", appname); + SendMsg( Error, Error, "already connected" ); +// bus->RemoveApplication( this ); + Close(); + } + break; + case EndRegexp: + +#ifdef DEBUG + TRACE("Regexp End id=%d\n", id); +#endif //DEBUG + + bus->CallApplicationConnectedCallback( this ); + AppConnectedCallbackCalled = true; + if ( !bus->ready_message.empty() ) + SendMsg( bus->ready_message.c_str() ); + break; + case Msg: + +#ifdef DEBUG + TRACE("Message id=%d msg='%s'\n", id, arg); +#endif //DEBUG + + arg = strtok( arg, ARG_END); + while ( arg ) + { + argv[argc++] = arg; + arg = strtok( NULL, ARG_END ); + } + bus->CallMessageCallback( this, id, argc, argv ); + break; + case DirectMsg: + +#ifdef DEBUG + TRACE("Direct Message id=%d msg='%s'\n", id, arg); +#endif //DEBUG + + bus->CallDirectMessageCallback( this, id, arg ); + break; + case Die: + +#ifdef DEBUG + TRACE("Die Message id=%d msg='%s'\n", id, arg); +#endif //DEBUG + + if ( bus->CallDieCallback( this, id, arg ) ) + { + PostMessage( NULL, WM_CLOSE, 0, 0); + } + break; + + default: + TRACE("Receive unhandled message %s\n", line); + break; + } +} + + +void IvyApplication::SendMsg(MsgType msg, int id, const char * arg) +{ + char buffer[1024]; + if ( arg ) + sprintf( buffer, "%d %d" ARG_START "%s\n", msg, id, arg ); + else sprintf( buffer, "%d %d" ARG_START "\n", msg, id ); + +#ifdef DEBUG + TRACE("SendMsg %s\n",buffer); +#endif //DEBUG + Send( buffer ); +} + +void IvyApplication::OnAccept(int nErrorCode) +{ + string remotehost; + UINT remoteport; + + // construct a new, empty socket + + IvyApplication *newapp = new IvyApplication(bus); + + // accept connection + + Accept( *newapp ); + newapp->GetPeerName( remotehost, remoteport ); + TRACE("Connexion de %s:%u\n", remotehost.c_str(), remoteport ); + bus->AddApplication( newapp ); +} + +void IvyApplication::OnClose(int nErrorCode) +{ + string remotehost; + UINT remoteport; + GetPeerName( remotehost, remoteport ); + TRACE("Deconnexion de %s:%u\n", remotehost.c_str(), remoteport ); + if ( AppConnectedCallbackCalled ) + bus->CallApplicationDisconnectedCallback( this ); +// bus->RemoveApplication( this ); + for ( int i = 0; i < regexp_in.size(); i++) + delete regexp_in[i]; + regexp_in.clear(); + Close(); +} + +int IvyApplication::SendMsg(const char *message) +{ + int count = 0; + Regexp *exp; + + /* send to already connected */ + for ( int id = 0; id < regexp_in.size(); id++ ) + { + exp = regexp_in[ id ]; + + if ( exp && exp->Match( message ) ) + { + string buffer; + for ( int i = 1; i < exp->SubStrings()+1; i++ ) + { + buffer += (*exp)[i]; + buffer += ARG_END; + } + SendMsg( Msg, id, buffer.c_str() ); + count++; + } + } + return count; +} + +const char *IvyApplication::GetName(void) +{ +return appname.c_str(); +} + + +BOOL IvyApplication::SameApplication(IvyApplication * app) +{ + string host1; + UINT port1; + string host2; + UINT port2; + if ( (remoteService != 0) && (remoteService == app->remoteService) ) + { + GetPeerName( host1, port1 ); + app->GetPeerName( host2, port2 ); + TRACE( "IvyApplication::SameApplication %s:%d %s:%d\n", host1.c_str(),port1, host2.c_str(),port2); + return ( host1 == host2 ); + } + return false; +} -- cgit v1.1 From 2e418cb4dd7804abf714cea0fb94903bad70a985 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:31 +0000 Subject: Utilisateur : Fcolin Date : 20/07/00 Heure : 10:57 Archivé dans $/Ivy (vss 2) --- Ivy/IvyApplication.cxx | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 26d0adf..de43bd0 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -129,20 +129,18 @@ void IvyApplication::OnReceive(char * line) TRACE("IvyApplication %s\n",err.c_str()); return; } - if ( id +1 < regexp_in.size() ) - regexp_in[ id ] = exp ; - else regexp_in.push_back( exp ); + regexp_in[ id ] = exp ; break; case DelRegexp: #ifdef DEBUG TRACE("Regexp Delete id=%d\n", id); #endif //DEBUG - if ( id < regexp_in.size() ) + if ( regexp_in.find(id) != regexp_in.end() ) { exp = regexp_in[ id ]; delete exp; - regexp_in[ id ] = NULL ; + regexp_in.erase( id ); } break; case StartRegexp: @@ -263,11 +261,12 @@ int IvyApplication::SendMsg(const char *message) { int count = 0; Regexp *exp; - + map::iterator iter; /* send to already connected */ - for ( int id = 0; id < regexp_in.size(); id++ ) + if ( !regexp_in.empty() ) + for ( iter = regexp_in.begin(); iter != regexp_in.end(); iter++ ) { - exp = regexp_in[ id ]; + exp = (*iter).second; if ( exp && exp->Match( message ) ) { @@ -277,7 +276,7 @@ int IvyApplication::SendMsg(const char *message) buffer += (*exp)[i]; buffer += ARG_END; } - SendMsg( Msg, id, buffer.c_str() ); + SendMsg( Msg, (*iter).first, buffer.c_str() ); count++; } } -- cgit v1.1 From 98f393ff247e0073b052cd7484584719cf93fdaf Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:33 +0000 Subject: Utilisateur : Fcolin Date : 30/11/00 Heure : 15:34 Archivé dans $/Ivy Commentaire: pb sur l'exit le postMessage se fait sur une Thread Ivy donc pas de fenetre (vss 3) --- Ivy/IvyApplication.cxx | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index de43bd0..cd0e70c 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -202,6 +202,7 @@ void IvyApplication::OnReceive(char * line) if ( bus->CallDieCallback( this, id, arg ) ) { PostMessage( NULL, WM_CLOSE, 0, 0); + exit(-1); } break; -- cgit v1.1 From db8db20b17a99485aaa54d8839f044acb99d29b9 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:35 +0000 Subject: Utilisateur : Fcolin Date : 16/01/01 Heure : 14:56 Archivé dans $/Ivy (vss 4) --- Ivy/IvyApplication.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index cd0e70c..d949845 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -115,7 +115,7 @@ void IvyApplication::OnReceive(char * line) if ( !bus->CheckRegexp( arg ) ) { #ifdef DEBUG - TRACE("Warning exp='%s' can't match removing from %s\n",arg,appname); + TRACE("Warning exp='%s' can't match removing from %s\n",arg,appname.c_str()); #endif //DEBUG return; } @@ -154,7 +154,7 @@ void IvyApplication::OnReceive(char * line) remoteService = id; if ( bus->CheckConnected( this ) ) { - TRACE("Quitting already connected %s\n", appname); + TRACE("Quitting already connected %s\n", appname.c_str()); SendMsg( Error, Error, "already connected" ); // bus->RemoveApplication( this ); Close(); -- cgit v1.1 From 439a1c2233af689583e026d1841578b241b335d0 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:37 +0000 Subject: Utilisateur : Fcolin Date : 23/01/01 Heure : 13:12 Archivé dans $/Ivy Commentaire: remove 'using name space std;' (vss 5) --- Ivy/IvyApplication.cxx | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index d949845..79110e1 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -49,7 +49,7 @@ void IvyApplication::Create(const char* host, UINT & port) UINT IvyApplication::Create() { - string host; + String host; UINT port; CBufferedSocket::Create(); // Max Listen Connexion @@ -122,9 +122,9 @@ void IvyApplication::OnReceive(char * line) exp = new Regexp( arg ); if ( !exp->CompiledOK() ) { - string regerr = exp->GetErrorString(); - string err; - err = "Error can't compile regexp '"+string(arg)+"' error "+regerr; + String regerr = exp->GetErrorString(); + String err; + err = "Error can't compile regexp '"+String(arg)+"' error "+regerr; SendMsg( Error, Error, err.c_str() ); TRACE("IvyApplication %s\n",err.c_str()); return; @@ -228,7 +228,7 @@ void IvyApplication::SendMsg(MsgType msg, int id, const char * arg) void IvyApplication::OnAccept(int nErrorCode) { - string remotehost; + String remotehost; UINT remoteport; // construct a new, empty socket @@ -245,7 +245,7 @@ void IvyApplication::OnAccept(int nErrorCode) void IvyApplication::OnClose(int nErrorCode) { - string remotehost; + String remotehost; UINT remoteport; GetPeerName( remotehost, remoteport ); TRACE("Deconnexion de %s:%u\n", remotehost.c_str(), remoteport ); @@ -262,7 +262,7 @@ int IvyApplication::SendMsg(const char *message) { int count = 0; Regexp *exp; - map::iterator iter; + std::map::iterator iter; /* send to already connected */ if ( !regexp_in.empty() ) for ( iter = regexp_in.begin(); iter != regexp_in.end(); iter++ ) @@ -271,7 +271,7 @@ int IvyApplication::SendMsg(const char *message) if ( exp && exp->Match( message ) ) { - string buffer; + String buffer; for ( int i = 1; i < exp->SubStrings()+1; i++ ) { buffer += (*exp)[i]; @@ -292,9 +292,9 @@ return appname.c_str(); BOOL IvyApplication::SameApplication(IvyApplication * app) { - string host1; + String host1; UINT port1; - string host2; + String host2; UINT port2; if ( (remoteService != 0) && (remoteService == app->remoteService) ) { -- cgit v1.1 From a2ad73d7b7c3812434be4d82eb1155dc4e6a6380 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:39 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 6) --- Ivy/IvyApplication.cxx | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 79110e1..7d55bf1 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -49,7 +49,7 @@ void IvyApplication::Create(const char* host, UINT & port) UINT IvyApplication::Create() { - String host; + string host; UINT port; CBufferedSocket::Create(); // Max Listen Connexion @@ -122,9 +122,9 @@ void IvyApplication::OnReceive(char * line) exp = new Regexp( arg ); if ( !exp->CompiledOK() ) { - String regerr = exp->GetErrorString(); - String err; - err = "Error can't compile regexp '"+String(arg)+"' error "+regerr; + string regerr = exp->GetErrorString(); + string err; + err = "Error can't compile regexp '"+string(arg)+"' error "+regerr; SendMsg( Error, Error, err.c_str() ); TRACE("IvyApplication %s\n",err.c_str()); return; @@ -228,7 +228,7 @@ void IvyApplication::SendMsg(MsgType msg, int id, const char * arg) void IvyApplication::OnAccept(int nErrorCode) { - String remotehost; + string remotehost; UINT remoteport; // construct a new, empty socket @@ -245,7 +245,7 @@ void IvyApplication::OnAccept(int nErrorCode) void IvyApplication::OnClose(int nErrorCode) { - String remotehost; + string remotehost; UINT remoteport; GetPeerName( remotehost, remoteport ); TRACE("Deconnexion de %s:%u\n", remotehost.c_str(), remoteport ); @@ -271,7 +271,7 @@ int IvyApplication::SendMsg(const char *message) if ( exp && exp->Match( message ) ) { - String buffer; + string buffer; for ( int i = 1; i < exp->SubStrings()+1; i++ ) { buffer += (*exp)[i]; @@ -292,9 +292,9 @@ return appname.c_str(); BOOL IvyApplication::SameApplication(IvyApplication * app) { - String host1; + string host1; UINT port1; - String host2; + string host2; UINT port2; if ( (remoteService != 0) && (remoteService == app->remoteService) ) { -- cgit v1.1 From 86f4b157ddaee8993b6e5b9591967a077ff8ff85 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:41 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 7) --- Ivy/IvyApplication.cxx | 33 +++++++++++++++++++-------------- 1 file changed, 19 insertions(+), 14 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 7d55bf1..cbb3ee6 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -2,7 +2,12 @@ // #include "stdafx.h" -//#include "libIvy.h" + +#ifdef _DEBUG +#define DEBUG_NEW new(__FILE__, __LINE__) +#define new DEBUG_NEW +#endif + #include "IvyApplication.h" #include "Regexp.h" @@ -26,7 +31,7 @@ IvyApplication::IvyApplication(Ivy * bus) IvyApplication::~IvyApplication() { // bus->RemoveApplication( this ); - for ( int i = 0; i < regexp_in.size(); i++) + for ( unsigned int i = 0; i < regexp_in.size(); i++) delete regexp_in[i]; regexp_in.clear(); if ( m_hSocket != INVALID_SOCKET ) @@ -122,25 +127,27 @@ void IvyApplication::OnReceive(char * line) exp = new Regexp( arg ); if ( !exp->CompiledOK() ) { - string regerr = exp->GetErrorString(); - string err; - err = "Error can't compile regexp '"+string(arg)+"' error "+regerr; + string err( "Error can't compile regexp '" ); + err += arg; + err += "' error "; + err += exp->GetErrorString(); SendMsg( Error, Error, err.c_str() ); TRACE("IvyApplication %s\n",err.c_str()); return; } - regexp_in[ id ] = exp ; + regexp_in.reserve( id +1 ); + regexp_in[ id ] = exp; break; case DelRegexp: #ifdef DEBUG TRACE("Regexp Delete id=%d\n", id); #endif //DEBUG - if ( regexp_in.find(id) != regexp_in.end() ) + if ( regexp_in[id] ) { exp = regexp_in[ id ]; delete exp; - regexp_in.erase( id ); + regexp_in[ id ] = NULL; } break; case StartRegexp: @@ -252,7 +259,7 @@ void IvyApplication::OnClose(int nErrorCode) if ( AppConnectedCallbackCalled ) bus->CallApplicationDisconnectedCallback( this ); // bus->RemoveApplication( this ); - for ( int i = 0; i < regexp_in.size(); i++) + for ( unsigned int i = 0; i < regexp_in.size(); i++) delete regexp_in[i]; regexp_in.clear(); Close(); @@ -262,12 +269,10 @@ int IvyApplication::SendMsg(const char *message) { int count = 0; Regexp *exp; - std::map::iterator iter; /* send to already connected */ - if ( !regexp_in.empty() ) - for ( iter = regexp_in.begin(); iter != regexp_in.end(); iter++ ) + for ( unsigned int i = 0; i < regexp_in.size(); i++ ) { - exp = (*iter).second; + exp = regexp_in[i]; if ( exp && exp->Match( message ) ) { @@ -277,7 +282,7 @@ int IvyApplication::SendMsg(const char *message) buffer += (*exp)[i]; buffer += ARG_END; } - SendMsg( Msg, (*iter).first, buffer.c_str() ); + SendMsg( Msg, i, buffer.c_str() ); count++; } } -- cgit v1.1 From a46b379fb2a8a1399606db6a753c85a6546f5336 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:43 +0000 Subject: Utilisateur : Fcolin Date : 14/02/01 Heure : 18:47 Archivé dans $/Ivy (vss 8) --- Ivy/IvyApplication.cxx | 52 +++++++++++++++++++++++++------------------------- 1 file changed, 26 insertions(+), 26 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index cbb3ee6..ef72bd1 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -11,7 +11,7 @@ #include "IvyApplication.h" #include "Regexp.h" -//#define DEBUG +#define IVY_DEBUG #define ARG_START "\002" #define ARG_END "\003" @@ -61,7 +61,7 @@ UINT IvyApplication::Create() Listen( SOMAXCONN ); GetSockName( host, port ); TRACE(" TCP %s:%d\n", host.c_str(), port ); -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE( "IvyApplication::Create server socket %d\n", m_hSocket ); #endif return port; @@ -78,9 +78,9 @@ void IvyApplication::OnReceive(char * line) const char *argv[Regexp::NSUBEXP]; char *arg; -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE("Receive %s\n",line); -#endif //DEBUG +#endif //IVY_DEBUG err = sscanf( line ,"%d %d", &kind_of_msg, &id); arg = strstr( line , ARG_START ); @@ -97,31 +97,31 @@ void IvyApplication::OnReceive(char * line) { case Bye: -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE("Quitting %s\n", line); -#endif //DEBUG +#endif //IVY_DEBUG // bus->RemoveApplication( this ); Close(); break; case Error: -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE("Receive error %d %s\n", id, arg); -#endif //DEBUG +#endif //IVY_DEBUG break; case AddRegexp: -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE("Regexp id=%d exp='%s'\n", id, arg); -#endif //DEBUG +#endif //IVY_DEBUG if ( !bus->CheckRegexp( arg ) ) { -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE("Warning exp='%s' can't match removing from %s\n",arg,appname.c_str()); -#endif //DEBUG +#endif //IVY_DEBUG return; } exp = new Regexp( arg ); @@ -140,9 +140,9 @@ void IvyApplication::OnReceive(char * line) break; case DelRegexp: -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE("Regexp Delete id=%d\n", id); -#endif //DEBUG +#endif //IVY_DEBUG if ( regexp_in[id] ) { exp = regexp_in[ id ]; @@ -152,9 +152,9 @@ void IvyApplication::OnReceive(char * line) break; case StartRegexp: -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE("Regexp Start id=%d\n", id); -#endif //DEBUG +#endif //IVY_DEBUG appname = arg; /* remote socket port */ @@ -169,9 +169,9 @@ void IvyApplication::OnReceive(char * line) break; case EndRegexp: -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE("Regexp End id=%d\n", id); -#endif //DEBUG +#endif //IVY_DEBUG bus->CallApplicationConnectedCallback( this ); AppConnectedCallbackCalled = true; @@ -180,9 +180,9 @@ void IvyApplication::OnReceive(char * line) break; case Msg: -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE("Message id=%d msg='%s'\n", id, arg); -#endif //DEBUG +#endif //IVY_DEBUG arg = strtok( arg, ARG_END); while ( arg ) @@ -194,17 +194,17 @@ void IvyApplication::OnReceive(char * line) break; case DirectMsg: -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE("Direct Message id=%d msg='%s'\n", id, arg); -#endif //DEBUG +#endif //IVY_DEBUG bus->CallDirectMessageCallback( this, id, arg ); break; case Die: -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE("Die Message id=%d msg='%s'\n", id, arg); -#endif //DEBUG +#endif //IVY_DEBUG if ( bus->CallDieCallback( this, id, arg ) ) { @@ -227,9 +227,9 @@ void IvyApplication::SendMsg(MsgType msg, int id, const char * arg) sprintf( buffer, "%d %d" ARG_START "%s\n", msg, id, arg ); else sprintf( buffer, "%d %d" ARG_START "\n", msg, id ); -#ifdef DEBUG +#ifdef IVY_DEBUG TRACE("SendMsg %s\n",buffer); -#endif //DEBUG +#endif //IVY_DEBUG Send( buffer ); } -- cgit v1.1 From 2ffcb31f76e9358254f9da9d9cefb9441a10dcaf Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:45 +0000 Subject: Utilisateur : Fcolin Date : 19/02/01 Heure : 10:37 Archivé dans $/Ivy (vss 9) --- Ivy/IvyApplication.cxx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index ef72bd1..2d1f937 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -11,7 +11,7 @@ #include "IvyApplication.h" #include "Regexp.h" -#define IVY_DEBUG +//#define IVY_DEBUG #define ARG_START "\002" #define ARG_END "\003" @@ -137,6 +137,9 @@ void IvyApplication::OnReceive(char * line) } regexp_in.reserve( id +1 ); regexp_in[ id ] = exp; +#ifdef IVY_DEBUG + TRACE("Adding regexp[%d]='%s'\n",id,arg); +#endif //IVY_DEBUG break; case DelRegexp: @@ -277,9 +280,9 @@ int IvyApplication::SendMsg(const char *message) if ( exp && exp->Match( message ) ) { string buffer; - for ( int i = 1; i < exp->SubStrings()+1; i++ ) + for ( int j = 1; j < exp->SubStrings()+1; j++ ) { - buffer += (*exp)[i]; + buffer += (*exp)[j]; buffer += ARG_END; } SendMsg( Msg, i, buffer.c_str() ); -- cgit v1.1 From f95aae747dc2b2511bd934d3084b24c77e895cf0 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:47 +0000 Subject: Utilisateur : Fcolin Date : 6/06/01 Heure : 8:50 Archivé dans $/Ivy Commentaire: Pb avec vector resize reserve et ajout de regexp !!! => replace list (vss 10) --- Ivy/IvyApplication.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 2d1f937..6d3b7ea 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -135,10 +135,10 @@ void IvyApplication::OnReceive(char * line) TRACE("IvyApplication %s\n",err.c_str()); return; } - regexp_in.reserve( id +1 ); + regexp_in.resize( id +1 ); regexp_in[ id ] = exp; #ifdef IVY_DEBUG - TRACE("Adding regexp[%d]='%s'\n",id,arg); + TRACE("Adding regexp[%d]='%s' size:%d\n",id,arg,regexp_in.size()); #endif //IVY_DEBUG break; case DelRegexp: -- cgit v1.1 From 362bf21b18d9bfd64e598d0a259f5d38bce5e7ac Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:49 +0000 Subject: Utilisateur : Fcolin Date : 17/07/01 Heure : 18:25 Archivé dans $/Ivy (vss 11) --- Ivy/IvyApplication.cxx | 5 ----- 1 file changed, 5 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 6d3b7ea..245381a 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -3,11 +3,6 @@ #include "stdafx.h" -#ifdef _DEBUG -#define DEBUG_NEW new(__FILE__, __LINE__) -#define new DEBUG_NEW -#endif - #include "IvyApplication.h" #include "Regexp.h" -- cgit v1.1 From d48ae3305891a6fab5d9ae1eee90afbe57934eb1 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:51 +0000 Subject: Utilisateur : Fcolin Date : 14/09/01 Heure : 16:44 Archivé dans $/Ivy Commentaire: correction BUG Ivy socket Listen apres start Listener et regexp_in.resize (vss 12) --- Ivy/IvyApplication.cxx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 245381a..33d62b0 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -6,7 +6,7 @@ #include "IvyApplication.h" #include "Regexp.h" -//#define IVY_DEBUG +#define IVY_DEBUG #define ARG_START "\002" #define ARG_END "\003" @@ -130,10 +130,11 @@ void IvyApplication::OnReceive(char * line) TRACE("IvyApplication %s\n",err.c_str()); return; } - regexp_in.resize( id +1 ); + if ( regexp_in.size() < (id + 1) ) + regexp_in.resize( id + 1 ); regexp_in[ id ] = exp; #ifdef IVY_DEBUG - TRACE("Adding regexp[%d]='%s' size:%d\n",id,arg,regexp_in.size()); + TRACE("Adding regexp[%d]='%s' size: %d\n",id,arg,regexp_in.size()); #endif //IVY_DEBUG break; case DelRegexp: -- cgit v1.1 From fd1b7bce694095d4cecb2724b6dfe71449f16f6f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:53 +0000 Subject: Utilisateur : Fcolin Date : 14/09/01 Heure : 16:53 Archivé dans $/Ivy (vss 13) --- Ivy/IvyApplication.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 33d62b0..b27b77b 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -6,7 +6,7 @@ #include "IvyApplication.h" #include "Regexp.h" -#define IVY_DEBUG +//#define IVY_DEBUG #define ARG_START "\002" #define ARG_END "\003" -- cgit v1.1 From 0a4563c486f43bf613730d1f00fb7ba876eae868 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:55 +0000 Subject: Utilisateur : Fcolin Date : 8/10/01 Heure : 14:15 Archivé dans $/Ivy Commentaire: bug strtok si argument vide !!! (vss 14) --- Ivy/IvyApplication.cxx | 24 +++++++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index b27b77b..7f798c2 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -11,7 +11,25 @@ #define ARG_START "\002" #define ARG_END "\003" - +/* +function like strok but do not eat consecutive separator +*/ +static char * nextArg( char *s, const char *separator ) +{ + static char *start = NULL; + static char *end = NULL; + if ( s ) + { + end = s; + } + start = end; + + while ( *end && *end != *separator ) + end++; + if ( *end == *separator ) *end++ = '\0'; + if ( end == start ) return NULL; + return start; +} ///////////////////////////////////////////////////////////////////////////// // IvyApplication @@ -183,11 +201,11 @@ void IvyApplication::OnReceive(char * line) TRACE("Message id=%d msg='%s'\n", id, arg); #endif //IVY_DEBUG - arg = strtok( arg, ARG_END); + arg = nextArg( arg, ARG_END); while ( arg ) { argv[argc++] = arg; - arg = strtok( NULL, ARG_END ); + arg = nextArg( NULL, ARG_END ); } bus->CallMessageCallback( this, id, argc, argv ); break; -- cgit v1.1 From 1da73b3dd4ed8ef47e7b1367ad99c5c1070423ff Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:57 +0000 Subject: Utilisateur : Fcolin Date : 10/06/02 Heure : 12:53 Archivé dans $/Ivy Commentaire: (vss 15) --- Ivy/IvyApplication.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 7f798c2..c4d4ed0 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -82,7 +82,8 @@ UINT IvyApplication::Create() void IvyApplication::OnReceive(char * line) { - int err,id; + int err; + unsigned int id; int kind_of_msg = Bye; Regexp *exp; -- cgit v1.1 From 67abfec93d33a97a97433e01d9efa78ab430ea45 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 12:59:59 +0000 Subject: Utilisateur : Fcolin Date : 14/11/02 Heure : 15:45 Archivé dans $/Bus/Ivy Commentaire: (vss 16) --- Ivy/IvyApplication.cxx | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index c4d4ed0..96023c7 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -11,6 +11,16 @@ #define ARG_START "\002" #define ARG_END "\003" +static char * firstArg( char *s, const char *separator ) +{ + char *ptr = s; + + while ( *ptr && *ptr != *separator ) + ptr++; + if ( *ptr == *separator ) + return ptr++ ; + else return NULL; +} /* function like strok but do not eat consecutive separator */ @@ -97,7 +107,7 @@ void IvyApplication::OnReceive(char * line) #endif //IVY_DEBUG err = sscanf( line ,"%d %d", &kind_of_msg, &id); - arg = strstr( line , ARG_START ); + arg = firstArg( line , ARG_START ); if ( (err != 2) || (arg == NULL) ) { TRACE("Quitting bad format %s\n", line); -- cgit v1.1 From 4cd382a0d401eb9a4447473555d82d30a8d44e16 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:01 +0000 Subject: Utilisateur : Fcolin Date : 15/12/03 Heure : 16:54 Archivé dans $/Bus/Ivy Commentaire: (vss 17) --- Ivy/IvyApplication.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 96023c7..008be70 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -126,7 +126,8 @@ void IvyApplication::OnReceive(char * line) #endif //IVY_DEBUG // bus->RemoveApplication( this ); - Close(); + OnClose(0); + //Close(); break; case Error: -- cgit v1.1 From fc091c2b6c66878f01575c3c24121f3dde9450a3 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:03 +0000 Subject: Utilisateur : Fcolin Date : 9/02/04 Heure : 16:14 Archivé dans $/Bus/Ivy Commentaire: (vss 18) --- Ivy/IvyApplication.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 008be70..f0d4f75 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -287,11 +287,12 @@ void IvyApplication::OnClose(int nErrorCode) TRACE("Deconnexion de %s:%u\n", remotehost.c_str(), remoteport ); if ( AppConnectedCallbackCalled ) bus->CallApplicationDisconnectedCallback( this ); -// bus->RemoveApplication( this ); + for ( unsigned int i = 0; i < regexp_in.size(); i++) delete regexp_in[i]; regexp_in.clear(); Close(); +// bus->RemoveApplication( this ); } int IvyApplication::SendMsg(const char *message) -- cgit v1.1 From 3340cd8c77dc2335915a3bb9a766f9a089774e1d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:05 +0000 Subject: Utilisateur : Fcolin Date : 3/03/05 Heure : 14:02 Archivé dans $/Bus/Ivy Commentaire: Passage a la lib PCRE (vss 19) --- Ivy/IvyApplication.cxx | 66 +++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 60 insertions(+), 6 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index f0d4f75..faafaf4 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -4,7 +4,8 @@ #include "stdafx.h" #include "IvyApplication.h" -#include "Regexp.h" + + //#define IVY_DEBUG @@ -55,7 +56,10 @@ IvyApplication::~IvyApplication() { // bus->RemoveApplication( this ); for ( unsigned int i = 0; i < regexp_in.size(); i++) +#ifdef USE_PCRE +#else delete regexp_in[i]; +#endif regexp_in.clear(); if ( m_hSocket != INVALID_SOCKET ) Close(); @@ -95,12 +99,19 @@ void IvyApplication::OnReceive(char * line) int err; unsigned int id; int kind_of_msg = Bye; + char *arg; + int argc = 0; + +#ifdef USE_PCRE + pcre *exp; + const char *argv[max_subexp]; + const char *errmsg; + int erroffset; +#else Regexp *exp; - - - int argc = 0; const char *argv[Regexp::NSUBEXP]; - char *arg; +#endif + #ifdef IVY_DEBUG TRACE("Receive %s\n",line); @@ -149,6 +160,19 @@ void IvyApplication::OnReceive(char * line) #endif //IVY_DEBUG return; } +#ifdef USE_PCRE + exp = pcre_compile( arg, PCRE_CASELESS, &errmsg, &erroffset, NULL ); + if ( !exp ) + { + string err( "Error can't compile regexp '" ); + err += arg; + err += "' error "; + err += errmsg; + SendMsg( Error, Error, err.c_str() ); + TRACE("IvyApplication %s\n",err.c_str()); + return; + } +#else exp = new Regexp( arg ); if ( !exp->CompiledOK() ) { @@ -160,6 +184,7 @@ void IvyApplication::OnReceive(char * line) TRACE("IvyApplication %s\n",err.c_str()); return; } +#endif if ( regexp_in.size() < (id + 1) ) regexp_in.resize( id + 1 ); regexp_in[ id ] = exp; @@ -175,7 +200,10 @@ void IvyApplication::OnReceive(char * line) if ( regexp_in[id] ) { exp = regexp_in[ id ]; +#ifdef USE_PCRE +#else delete exp; +#endif regexp_in[ id ] = NULL; } break; @@ -289,7 +317,11 @@ void IvyApplication::OnClose(int nErrorCode) bus->CallApplicationDisconnectedCallback( this ); for ( unsigned int i = 0; i < regexp_in.size(); i++) +#ifdef USE_PCRE + pcre_free( regexp_in[i] ); +#else delete regexp_in[i]; +#endif regexp_in.clear(); Close(); // bus->RemoveApplication( this ); @@ -298,12 +330,33 @@ void IvyApplication::OnClose(int nErrorCode) int IvyApplication::SendMsg(const char *message) { int count = 0; +#ifdef USE_PCRE + pcre *exp; + int ovector[max_subexp*3]; +#else Regexp *exp; +#endif /* send to already connected */ for ( unsigned int i = 0; i < regexp_in.size(); i++ ) { exp = regexp_in[i]; - +#ifdef USE_PCRE + int match_count = pcre_exec( exp, NULL, message, strlen( message ), 0, 0, ovector, max_subexp ); + if ( match_count > 1 ) + { + string buffer; + const char *substring; + for ( int j = 1; j < match_count; j++ ) + { + pcre_get_substring(message, ovector, match_count, j, &substring); + buffer += substring; + buffer += ARG_END; + pcre_free_substring( substring ); + } + SendMsg( Msg, i, buffer.c_str() ); + count++; + } +#else if ( exp && exp->Match( message ) ) { string buffer; @@ -315,6 +368,7 @@ int IvyApplication::SendMsg(const char *message) SendMsg( Msg, i, buffer.c_str() ); count++; } +#endif } return count; } -- cgit v1.1 From 03f69b1c55a75ecf83a81ec4a342b924c95b68e5 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:07 +0000 Subject: Utilisateur : Fcolin Date : 8/03/05 Heure : 15:20 Archivé dans $/Bus/Ivy Commentaire: Bug en cas d'expression vide de subexpression (vss 20) --- Ivy/IvyApplication.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index faafaf4..23abfbf 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -342,7 +342,7 @@ int IvyApplication::SendMsg(const char *message) exp = regexp_in[i]; #ifdef USE_PCRE int match_count = pcre_exec( exp, NULL, message, strlen( message ), 0, 0, ovector, max_subexp ); - if ( match_count > 1 ) + if ( match_count > 0 ) { string buffer; const char *substring; -- cgit v1.1 From 009f570f9c4e60137201d782d7c1f6a3b918232f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:09 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:45 Archivé dans $/Bus/Ivy Commentaire: (vss 21) --- Ivy/IvyApplication.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 23abfbf..3eaecdb 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -1,7 +1,7 @@ // IvyApplication.cpp : implementation file // -#include "stdafx.h" +#include "IvyStdAfx.h" #include "IvyApplication.h" @@ -281,7 +281,7 @@ void IvyApplication::SendMsg(MsgType msg, int id, const char * arg) { char buffer[1024]; if ( arg ) - sprintf( buffer, "%d %d" ARG_START "%s\n", msg, id, arg ); + _snprintf( buffer, sizeof( buffer ), "%d %d" ARG_START "%s\n", msg, id, arg ); else sprintf( buffer, "%d %d" ARG_START "\n", msg, id ); #ifdef IVY_DEBUG -- cgit v1.1 From f872905e098d43cc350bfad3903a8ce9756e07e2 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:11 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 22) --- Ivy/IvyApplication.cxx | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 3eaecdb..fb399a6 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -81,7 +81,7 @@ void IvyApplication::Create(const char* host, UINT & port) UINT IvyApplication::Create() { - string host; + ivy::string host; UINT port; CBufferedSocket::Create(); // Max Listen Connexion @@ -164,7 +164,7 @@ void IvyApplication::OnReceive(char * line) exp = pcre_compile( arg, PCRE_CASELESS, &errmsg, &erroffset, NULL ); if ( !exp ) { - string err( "Error can't compile regexp '" ); + ivy::string err( "Error can't compile regexp '" ); err += arg; err += "' error "; err += errmsg; @@ -176,7 +176,7 @@ void IvyApplication::OnReceive(char * line) exp = new Regexp( arg ); if ( !exp->CompiledOK() ) { - string err( "Error can't compile regexp '" ); + ivy::string err( "Error can't compile regexp '" ); err += arg; err += "' error "; err += exp->GetErrorString(); @@ -292,7 +292,7 @@ void IvyApplication::SendMsg(MsgType msg, int id, const char * arg) void IvyApplication::OnAccept(int nErrorCode) { - string remotehost; + ivy::string remotehost; UINT remoteport; // construct a new, empty socket @@ -309,7 +309,7 @@ void IvyApplication::OnAccept(int nErrorCode) void IvyApplication::OnClose(int nErrorCode) { - string remotehost; + ivy::string remotehost; UINT remoteport; GetPeerName( remotehost, remoteport ); TRACE("Deconnexion de %s:%u\n", remotehost.c_str(), remoteport ); @@ -344,7 +344,7 @@ int IvyApplication::SendMsg(const char *message) int match_count = pcre_exec( exp, NULL, message, strlen( message ), 0, 0, ovector, max_subexp ); if ( match_count > 0 ) { - string buffer; + ivy::string buffer; const char *substring; for ( int j = 1; j < match_count; j++ ) { @@ -359,7 +359,7 @@ int IvyApplication::SendMsg(const char *message) #else if ( exp && exp->Match( message ) ) { - string buffer; + ivy::string buffer; for ( int j = 1; j < exp->SubStrings()+1; j++ ) { buffer += (*exp)[j]; @@ -381,9 +381,9 @@ return appname.c_str(); BOOL IvyApplication::SameApplication(IvyApplication * app) { - string host1; + ivy::string host1; UINT port1; - string host2; + ivy::string host2; UINT port2; if ( (remoteService != 0) && (remoteService == app->remoteService) ) { -- cgit v1.1 From 914228ac4531f1ea31ae2987ab875017a28e3b57 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:13 +0000 Subject: Utilisateur : Fcolin Date : 14/06/05 Heure : 11:02 Archivé dans $/Bus/Ivy Commentaire: get all the pcre sublist in one time (vss 23) --- Ivy/IvyApplication.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index fb399a6..91a2d98 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -345,14 +345,14 @@ int IvyApplication::SendMsg(const char *message) if ( match_count > 0 ) { ivy::string buffer; - const char *substring; + const char **substring; + pcre_get_substring_list(message,ovector, match_count, &substring); for ( int j = 1; j < match_count; j++ ) { - pcre_get_substring(message, ovector, match_count, j, &substring); - buffer += substring; + buffer += substring[j]; buffer += ARG_END; - pcre_free_substring( substring ); } + pcre_free_substring_list(substring); SendMsg( Msg, i, buffer.c_str() ); count++; } -- cgit v1.1 From 80dc36e4b37ee8b6de9b9b3d6954f6ec11d43324 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:15 +0000 Subject: Utilisateur : Fcolin Date : 14/06/05 Heure : 11:37 Archivé dans $/Bus/Ivy Commentaire: (vss 24) --- Ivy/IvyApplication.cxx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 91a2d98..7ed553c 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -346,7 +346,12 @@ int IvyApplication::SendMsg(const char *message) { ivy::string buffer; const char **substring; - pcre_get_substring_list(message,ovector, match_count, &substring); + int err = pcre_get_substring_list(message,ovector, match_count, &substring); + if ( err != 0 ) + { + SendMsg( Error, Error, "Memory Alloc Error" ); + } + else { for ( int j = 1; j < match_count; j++ ) { buffer += substring[j]; @@ -355,6 +360,7 @@ int IvyApplication::SendMsg(const char *message) pcre_free_substring_list(substring); SendMsg( Msg, i, buffer.c_str() ); count++; + } } #else if ( exp && exp->Match( message ) ) -- cgit v1.1 From 66549353d2e6f98710579f6af961e2d10ec2b031 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:17 +0000 Subject: Utilisateur : Fcolin Date : 28/06/05 Heure : 14:14 Archivé dans $/Bus/Ivy Commentaire: (vss 25) --- Ivy/IvyApplication.cxx | 2 ++ 1 file changed, 2 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 7ed553c..6aa3668 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -57,6 +57,7 @@ IvyApplication::~IvyApplication() // bus->RemoveApplication( this ); for ( unsigned int i = 0; i < regexp_in.size(); i++) #ifdef USE_PCRE + pcre_free( regexp_in[i] ); #else delete regexp_in[i]; #endif @@ -201,6 +202,7 @@ void IvyApplication::OnReceive(char * line) { exp = regexp_in[ id ]; #ifdef USE_PCRE + pcre_free( exp ); #else delete exp; #endif -- cgit v1.1 From 896c064fa646fb30d446aaf66567f81d7590f9e9 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:19 +0000 Subject: Utilisateur : Fcolin Date : 16/11/05 Heure : 9:54 Archivé dans $/Bus/Ivy Commentaire: 64 bits ports (vss 26) --- Ivy/IvyApplication.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 6aa3668..5a50b96 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -118,7 +118,7 @@ void IvyApplication::OnReceive(char * line) TRACE("Receive %s\n",line); #endif //IVY_DEBUG - err = sscanf( line ,"%d %d", &kind_of_msg, &id); + err = sscanf_s( line ,"%d %d", &kind_of_msg, &id); arg = firstArg( line , ARG_START ); if ( (err != 2) || (arg == NULL) ) { @@ -283,8 +283,8 @@ void IvyApplication::SendMsg(MsgType msg, int id, const char * arg) { char buffer[1024]; if ( arg ) - _snprintf( buffer, sizeof( buffer ), "%d %d" ARG_START "%s\n", msg, id, arg ); - else sprintf( buffer, "%d %d" ARG_START "\n", msg, id ); + _snprintf_s( buffer, sizeof( buffer ),sizeof( buffer )-1, "%d %d" ARG_START "%s\n", msg, id, arg ); + else sprintf_s( buffer,sizeof( buffer ), "%d %d" ARG_START "\n", msg, id ); #ifdef IVY_DEBUG TRACE("SendMsg %s\n",buffer); @@ -343,7 +343,7 @@ int IvyApplication::SendMsg(const char *message) { exp = regexp_in[i]; #ifdef USE_PCRE - int match_count = pcre_exec( exp, NULL, message, strlen( message ), 0, 0, ovector, max_subexp ); + int match_count = pcre_exec( exp, NULL, message, (int) strlen( message ), 0, 0, ovector, max_subexp ); if ( match_count > 0 ) { ivy::string buffer; -- cgit v1.1 From 2132f900f65f521c61e60a3541716104d83ee384 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:21 +0000 Subject: Utilisateur : Fcolin Date : 17/11/05 Heure : 15:08 Archivé dans $/Bus/Ivy Commentaire: nice Bug in nextArg not reentrant routine due to static variable (vss 27) --- Ivy/IvyApplication.cxx | 36 +++++++++++++++++------------------- 1 file changed, 17 insertions(+), 19 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 5a50b96..32b89a2 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -9,36 +9,32 @@ //#define IVY_DEBUG -#define ARG_START "\002" -#define ARG_END "\003" +#define ARG_START 2 +#define ARG_END 3 -static char * firstArg( char *s, const char *separator ) +static char * firstArg( char *s, const char separator ) { char *ptr = s; - while ( *ptr && *ptr != *separator ) + while ( *ptr && *ptr != separator ) ptr++; - if ( *ptr == *separator ) + if ( *ptr == separator ) return ptr++ ; else return NULL; } /* function like strok but do not eat consecutive separator */ -static char * nextArg( char *s, const char *separator ) +static char * nextArg( char **s, const char separator ) { - static char *start = NULL; - static char *end = NULL; - if ( s ) - { - end = s; - } - start = end; + char *start = *s; + char *end = *s; - while ( *end && *end != *separator ) + while ( *end && *end != separator ) end++; - if ( *end == *separator ) *end++ = '\0'; + if ( *end == separator ) *end++ = '\0'; if ( end == start ) return NULL; + *s = end; return start; } ///////////////////////////////////////////////////////////////////////////// @@ -102,6 +98,7 @@ void IvyApplication::OnReceive(char * line) int kind_of_msg = Bye; char *arg; int argc = 0; + char *arg_ptr; #ifdef USE_PCRE pcre *exp; @@ -243,11 +240,12 @@ void IvyApplication::OnReceive(char * line) TRACE("Message id=%d msg='%s'\n", id, arg); #endif //IVY_DEBUG - arg = nextArg( arg, ARG_END); + arg_ptr = arg; + arg = nextArg( &arg_ptr, ARG_END); while ( arg ) { argv[argc++] = arg; - arg = nextArg( NULL, ARG_END ); + arg = nextArg( &arg_ptr, ARG_END ); } bus->CallMessageCallback( this, id, argc, argv ); break; @@ -283,8 +281,8 @@ void IvyApplication::SendMsg(MsgType msg, int id, const char * arg) { char buffer[1024]; if ( arg ) - _snprintf_s( buffer, sizeof( buffer ),sizeof( buffer )-1, "%d %d" ARG_START "%s\n", msg, id, arg ); - else sprintf_s( buffer,sizeof( buffer ), "%d %d" ARG_START "\n", msg, id ); + _snprintf_s( buffer, sizeof( buffer ),sizeof( buffer )-1, "%d %d%c%s\n", msg, id, ARG_START, arg ); + else sprintf_s( buffer,sizeof( buffer ), "%d %d%c\n", msg, id, ARG_START); #ifdef IVY_DEBUG TRACE("SendMsg %s\n",buffer); -- cgit v1.1 From 836c3cea5435c0313827691cb6cc71de3c872237 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:23 +0000 Subject: Utilisateur : Fcolin Date : 18/11/05 Heure : 11:46 Archivé dans $/Bus/Ivy Commentaire: repassage a la STL et correction bug multithread (vss 28) --- Ivy/IvyApplication.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 32b89a2..b0fa052 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -324,7 +324,7 @@ void IvyApplication::OnClose(int nErrorCode) #endif regexp_in.clear(); Close(); -// bus->RemoveApplication( this ); + //bus->RemoveApplication( this ); } int IvyApplication::SendMsg(const char *message) -- cgit v1.1 From abb65226983bbee29c17c004b75bc50918d15003 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:25 +0000 Subject: Utilisateur : Fcolin Date : 19/04/06 Heure : 15:07 Archivé dans $/Bus/Ivy Commentaire: (vss 29) --- Ivy/IvyApplication.cxx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index b0fa052..c9ba0e4 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -162,12 +162,12 @@ void IvyApplication::OnReceive(char * line) exp = pcre_compile( arg, PCRE_CASELESS, &errmsg, &erroffset, NULL ); if ( !exp ) { - ivy::string err( "Error can't compile regexp '" ); - err += arg; - err += "' error "; - err += errmsg; - SendMsg( Error, Error, err.c_str() ); - TRACE("IvyApplication %s\n",err.c_str()); + ivy::string errstr( "Error can't compile regexp '" ); + errstr += arg; + errstr += "' error "; + errstr += errmsg; + SendMsg( Error, Error, errstr.c_str() ); + TRACE("IvyApplication %s\n",errstr.c_str()); return; } #else -- cgit v1.1 From 4a8451ff484c9fe7656acab4edd61713e2212ed6 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:27 +0000 Subject: Utilisateur : Fcolin Date : 23/05/06 Heure : 18:18 Archivé dans $/Bus/Ivy Commentaire: Modification protocol UDP (vss 30) --- Ivy/IvyApplication.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index c9ba0e4..c4de075 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -67,8 +67,9 @@ IvyApplication::~IvyApplication() // IvyApplication member functions -void IvyApplication::Create(const char* host, UINT & port) +void IvyApplication::Create(const char* host, UINT & port, const char* name) { + appname = name; // Exception to catch CBufferedSocket::Create(); Connect(host, port); -- cgit v1.1 From 8e63bb805a09c8c1bd019347071dad478ea034b9 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:29 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 10:14 Archivé dans $/Bus/Ivy Commentaire: ajout Binding Callback et SetFilter (vss 31) --- Ivy/IvyApplication.cxx | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index c4de075..c3f6f02 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -157,6 +157,7 @@ void IvyApplication::OnReceive(char * line) #ifdef IVY_DEBUG TRACE("Warning exp='%s' can't match removing from %s\n",arg,appname.c_str()); #endif //IVY_DEBUG + bus->CallBindingFilterCallback( this, id, arg ); return; } #ifdef USE_PCRE @@ -185,11 +186,16 @@ void IvyApplication::OnReceive(char * line) } #endif if ( regexp_in.size() < (id + 1) ) + { regexp_in.resize( id + 1 ); + regexp_str_in.resize( id + 1 ); + } regexp_in[ id ] = exp; + regexp_str_in[ id ] = arg; #ifdef IVY_DEBUG TRACE("Adding regexp[%d]='%s' size: %d\n",id,arg,regexp_in.size()); #endif //IVY_DEBUG + bus->CallBindingAddCallback( this, id, arg ); break; case DelRegexp: @@ -199,6 +205,7 @@ void IvyApplication::OnReceive(char * line) if ( regexp_in[id] ) { exp = regexp_in[ id ]; + bus->CallBindingRemoveCallback( this, id, regexp_str_in[id].c_str() ); #ifdef USE_PCRE pcre_free( exp ); #else -- cgit v1.1 From ea91919a2278f4894f11b47d1397e99f4a28f85f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:31 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 15:54 Archivé dans $/Bus/Ivy Commentaire: Separation module de traitement regexp (vss 32) --- Ivy/IvyApplication.cxx | 92 ++++++++++++-------------------------------------- 1 file changed, 21 insertions(+), 71 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index c3f6f02..53341bc 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -4,7 +4,7 @@ #include "IvyStdAfx.h" #include "IvyApplication.h" - +#include "IvyBinding.h" //#define IVY_DEBUG @@ -52,11 +52,7 @@ IvyApplication::~IvyApplication() { // bus->RemoveApplication( this ); for ( unsigned int i = 0; i < regexp_in.size(); i++) -#ifdef USE_PCRE - pcre_free( regexp_in[i] ); -#else delete regexp_in[i]; -#endif regexp_in.clear(); if ( m_hSocket != INVALID_SOCKET ) Close(); @@ -100,18 +96,13 @@ void IvyApplication::OnReceive(char * line) char *arg; int argc = 0; char *arg_ptr; - -#ifdef USE_PCRE - pcre *exp; + static const int max_subexp = 200; const char *argv[max_subexp]; - const char *errmsg; - int erroffset; -#else - Regexp *exp; - const char *argv[Regexp::NSUBEXP]; -#endif - + IvyBinding *exp; + int erroffset; + const char *errmsg; + #ifdef IVY_DEBUG TRACE("Receive %s\n",line); #endif //IVY_DEBUG @@ -152,7 +143,7 @@ void IvyApplication::OnReceive(char * line) TRACE("Regexp id=%d exp='%s'\n", id, arg); #endif //IVY_DEBUG - if ( !bus->CheckRegexp( arg ) ) + if ( !IvyBinding::Filter( arg ) ) { #ifdef IVY_DEBUG TRACE("Warning exp='%s' can't match removing from %s\n",arg,appname.c_str()); @@ -160,9 +151,8 @@ void IvyApplication::OnReceive(char * line) bus->CallBindingFilterCallback( this, id, arg ); return; } -#ifdef USE_PCRE - exp = pcre_compile( arg, PCRE_CASELESS, &errmsg, &erroffset, NULL ); - if ( !exp ) + exp = new IvyBinding(); + if ( !exp->Compile(arg, &erroffset, &errmsg ) ) { ivy::string errstr( "Error can't compile regexp '" ); errstr += arg; @@ -170,21 +160,10 @@ void IvyApplication::OnReceive(char * line) errstr += errmsg; SendMsg( Error, Error, errstr.c_str() ); TRACE("IvyApplication %s\n",errstr.c_str()); + delete exp; return; } -#else - exp = new Regexp( arg ); - if ( !exp->CompiledOK() ) - { - ivy::string err( "Error can't compile regexp '" ); - err += arg; - err += "' error "; - err += exp->GetErrorString(); - SendMsg( Error, Error, err.c_str() ); - TRACE("IvyApplication %s\n",err.c_str()); - return; - } -#endif + if ( regexp_in.size() < (id + 1) ) { regexp_in.resize( id + 1 ); @@ -206,11 +185,8 @@ void IvyApplication::OnReceive(char * line) { exp = regexp_in[ id ]; bus->CallBindingRemoveCallback( this, id, regexp_str_in[id].c_str() ); -#ifdef USE_PCRE - pcre_free( exp ); -#else + delete exp; -#endif regexp_in[ id ] = NULL; } break; @@ -325,11 +301,7 @@ void IvyApplication::OnClose(int nErrorCode) bus->CallApplicationDisconnectedCallback( this ); for ( unsigned int i = 0; i < regexp_in.size(); i++) -#ifdef USE_PCRE - pcre_free( regexp_in[i] ); -#else delete regexp_in[i]; -#endif regexp_in.clear(); Close(); //bus->RemoveApplication( this ); @@ -338,51 +310,29 @@ void IvyApplication::OnClose(int nErrorCode) int IvyApplication::SendMsg(const char *message) { int count = 0; -#ifdef USE_PCRE - pcre *exp; - int ovector[max_subexp*3]; -#else - Regexp *exp; -#endif + IvyBinding *exp; + /* send to already connected */ for ( unsigned int i = 0; i < regexp_in.size(); i++ ) { exp = regexp_in[i]; -#ifdef USE_PCRE - int match_count = pcre_exec( exp, NULL, message, (int) strlen( message ), 0, 0, ovector, max_subexp ); + int match_count = exp->Exec( message ); if ( match_count > 0 ) { ivy::string buffer; - const char **substring; - int err = pcre_get_substring_list(message,ovector, match_count, &substring); - if ( err != 0 ) - { - SendMsg( Error, Error, "Memory Alloc Error" ); - } - else { + int arglen; + const char *arg; + for ( int j = 1; j < match_count; j++ ) { - buffer += substring[j]; + exp->Match(message, j, &arglen, &arg); + buffer += arg; buffer += ARG_END; } - pcre_free_substring_list(substring); SendMsg( Msg, i, buffer.c_str() ); count++; - } } -#else - if ( exp && exp->Match( message ) ) - { - ivy::string buffer; - for ( int j = 1; j < exp->SubStrings()+1; j++ ) - { - buffer += (*exp)[j]; - buffer += ARG_END; - } - SendMsg( Msg, i, buffer.c_str() ); - count++; - } -#endif + } return count; } -- cgit v1.1 From c7734bf97cb2c4df14edd238257b95a6136c614a Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:33 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 16:40 Archivé dans $/Bus/Ivy Commentaire: correction bug du a la separation du module regexp transformation des tables de regexp en table de Hash (vss 33) --- Ivy/IvyApplication.cxx | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index 53341bc..bad4910 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -51,8 +51,8 @@ IvyApplication::IvyApplication(Ivy * bus) IvyApplication::~IvyApplication() { // bus->RemoveApplication( this ); - for ( unsigned int i = 0; i < regexp_in.size(); i++) - delete regexp_in[i]; + for ( Bindings::iterator iter = regexp_in.begin( ); iter != regexp_in.end( ); iter++ ) + delete iter->second; regexp_in.clear(); if ( m_hSocket != INVALID_SOCKET ) Close(); @@ -164,11 +164,11 @@ void IvyApplication::OnReceive(char * line) return; } - if ( regexp_in.size() < (id + 1) ) + /*if ( regexp_in.size() < (id + 1) ) { regexp_in.resize( id + 1 ); regexp_str_in.resize( id + 1 ); - } + }*/ regexp_in[ id ] = exp; regexp_str_in[ id ] = arg; #ifdef IVY_DEBUG @@ -300,8 +300,8 @@ void IvyApplication::OnClose(int nErrorCode) if ( AppConnectedCallbackCalled ) bus->CallApplicationDisconnectedCallback( this ); - for ( unsigned int i = 0; i < regexp_in.size(); i++) - delete regexp_in[i]; + for ( Bindings::iterator iter = regexp_in.begin( ); iter != regexp_in.end( ); iter++) + delete iter->second; regexp_in.clear(); Close(); //bus->RemoveApplication( this ); @@ -313,9 +313,11 @@ int IvyApplication::SendMsg(const char *message) IvyBinding *exp; /* send to already connected */ - for ( unsigned int i = 0; i < regexp_in.size(); i++ ) + for ( Bindings::iterator iter = regexp_in.begin( ); iter != regexp_in.end( ); iter++ ) { - exp = regexp_in[i]; + exp = iter->second; + if ( !exp ) + continue; int match_count = exp->Exec( message ); if ( match_count > 0 ) { @@ -326,10 +328,10 @@ int IvyApplication::SendMsg(const char *message) for ( int j = 1; j < match_count; j++ ) { exp->Match(message, j, &arglen, &arg); - buffer += arg; + buffer += ivy::string(arg,arglen ); buffer += ARG_END; } - SendMsg( Msg, i, buffer.c_str() ); + SendMsg( Msg, iter->first, buffer.c_str() ); count++; } -- cgit v1.1 From 27cc7f3435b1561d686aa214c5083aa2a41b39f1 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:35 +0000 Subject: Utilisateur : Fcolin Date : 1/08/06 Heure : 9:48 Archivé dans $/Bus/Ivy Commentaire: (vss 34) --- Ivy/IvyApplication.cxx | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.cxx b/Ivy/IvyApplication.cxx index bad4910..07f37be 100644 --- a/Ivy/IvyApplication.cxx +++ b/Ivy/IvyApplication.cxx @@ -253,6 +253,19 @@ void IvyApplication::OnReceive(char * line) exit(-1); } break; + case Ping: +#ifdef IVY_DEBUG + TRACE("Ping Message\n"); +#endif //IVY_DEBUG + this->SendMsg( Pong, 0, "beurk" ); + break; + + case Pong: +#ifdef IVY_DEBUG + TRACE("Pong Message\n"); +#endif //IVY_DEBUG + TRACE("Receive unhandled Pong message (ivy-c++ not able to send ping)\n"); + break; default: TRACE("Receive unhandled message %s\n", line); -- cgit v1.1 From 500e25c685a49ff50e486a23f2171cd1b737f140 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:37 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/IvyApplication.h | 80 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 Ivy/IvyApplication.h (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h new file mode 100644 index 0000000..8884735 --- /dev/null +++ b/Ivy/IvyApplication.h @@ -0,0 +1,80 @@ +#if !defined(AFX_BUSAPPLICATION_H__F7F08FE8_E653_11D0_AE3E_080009F92591__INCLUDED_) +#define AFX_BUSAPPLICATION_H__F7F08FE8_E653_11D0_AE3E_080009F92591__INCLUDED_ + +#if _MSC_VER >= 1000 +#pragma once +#endif // _MSC_VER >= 1000 +// IvyApplication.h : header file +// +#include "BufferedSocket.h" +#include "Ivy.h" + +class Regexp; + +///////////////////////////////////////////////////////////////////////////// +// IvyApplication command target + +class IvyApplication : public CBufferedSocket +{ +// Attributes +public: + + + typedef enum { + + Bye, /* quit l'application ( non utilise ) */ + AddRegexp, /* expression reguliere d'un client */ + Msg, /* message reel */ + Error, /* error message */ + DelRegexp, /* Remove expression reguliere */ + EndRegexp, /* end of the regexp list */ + StartRegexp, /* debut des expressions */ + DirectMsg, /* message direct a destination de l'appli */ + Die /* demande de terminaison de l'appli */ + + }MsgType; + + +// Operations +public: + IvyApplication(Ivy *bus); + virtual ~IvyApplication(); + +// Overrides +public: + BOOL SameApplication( IvyApplication *app ); + UINT remoteService; + const char *GetName(void); + int SendMsg( const char *message ); + void SendMsg( MsgType msg, int id, const char * arg = NULL); + UINT Create(); + void OnReceive( char *line ); + void Create( const char * host, UINT &port ); + // ClassWizard generated virtual function overrides + //{{AFX_VIRTUAL(IvyApplication) + public: + virtual void OnAccept(int nErrorCode); + virtual void OnClose(int nErrorCode); + //}}AFX_VIRTUAL + + // Generated message map functions + //{{AFX_MSG(IvyApplication) + // NOTE - the ClassWizard will add and remove member functions here. + //}}AFX_MSG + +// Implementation +protected: + string appname; + bool AppConnectedCallbackCalled; + Ivy *bus; + /* liste des souscriptions remote */ + vector regexp_in; + +}; + +///////////////////////////////////////////////////////////////////////////// + +//{{AFX_INSERT_LOCATION}} +// Microsoft Developer Studio will insert additional declarations immediately before the previous line. + +#endif // !defined(AFX_BUSAPPLICATION_H__F7F08FE8_E653_11D0_AE3E_080009F92591__INCLUDED_) -- cgit v1.1 From e4d99620849c75fa3c993636de25c29a1dd00d2b Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:40 +0000 Subject: Utilisateur : Fcolin Date : 20/07/00 Heure : 10:57 Archivé dans $/Ivy (vss 2) --- Ivy/IvyApplication.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index 8884735..d7823f0 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -68,7 +68,7 @@ protected: bool AppConnectedCallbackCalled; Ivy *bus; /* liste des souscriptions remote */ - vector regexp_in; + map regexp_in; }; -- cgit v1.1 From f244a5f6162f4fa06f78844dc32edb8d23cf1b03 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:41 +0000 Subject: Utilisateur : Fcolin Date : 23/01/01 Heure : 13:12 Archivé dans $/Ivy Commentaire: remove 'using name space std;' (vss 3) --- Ivy/IvyApplication.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index d7823f0..8a31888 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -64,11 +64,11 @@ public: // Implementation protected: - string appname; + String appname; bool AppConnectedCallbackCalled; Ivy *bus; /* liste des souscriptions remote */ - map regexp_in; + std::map regexp_in; }; -- cgit v1.1 From bd891794763914ac8e2aed8530512eabfe5ccdfe Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:43 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 4) --- Ivy/IvyApplication.h | 24 +++--------------------- 1 file changed, 3 insertions(+), 21 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index 8a31888..13e7534 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -1,9 +1,6 @@ -#if !defined(AFX_BUSAPPLICATION_H__F7F08FE8_E653_11D0_AE3E_080009F92591__INCLUDED_) -#define AFX_BUSAPPLICATION_H__F7F08FE8_E653_11D0_AE3E_080009F92591__INCLUDED_ -#if _MSC_VER >= 1000 #pragma once -#endif // _MSC_VER >= 1000 + // IvyApplication.h : header file // #include "BufferedSocket.h" @@ -50,31 +47,16 @@ public: UINT Create(); void OnReceive( char *line ); void Create( const char * host, UINT &port ); - // ClassWizard generated virtual function overrides - //{{AFX_VIRTUAL(IvyApplication) - public: virtual void OnAccept(int nErrorCode); virtual void OnClose(int nErrorCode); - //}}AFX_VIRTUAL - // Generated message map functions - //{{AFX_MSG(IvyApplication) - // NOTE - the ClassWizard will add and remove member functions here. - //}}AFX_MSG // Implementation protected: - String appname; + string appname; bool AppConnectedCallbackCalled; Ivy *bus; /* liste des souscriptions remote */ - std::map regexp_in; + map regexp_in; }; - -///////////////////////////////////////////////////////////////////////////// - -//{{AFX_INSERT_LOCATION}} -// Microsoft Developer Studio will insert additional declarations immediately before the previous line. - -#endif // !defined(AFX_BUSAPPLICATION_H__F7F08FE8_E653_11D0_AE3E_080009F92591__INCLUDED_) -- cgit v1.1 From b2b0d35764eb7b161b863259fd3c85ff913382ab Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:45 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 5) --- Ivy/IvyApplication.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index 13e7534..2f97805 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -57,6 +57,7 @@ protected: bool AppConnectedCallbackCalled; Ivy *bus; /* liste des souscriptions remote */ - map regexp_in; + typedef vector RegexpVector; + RegexpVector regexp_in; }; -- cgit v1.1 From 691f8caef0ed2b55a8e481d1dd62ff1fc36856c2 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:47 +0000 Subject: Utilisateur : Fcolin Date : 25/10/01 Heure : 18:39 Archivé dans $/Ivy (vss 6) --- Ivy/IvyApplication.h | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index 2f97805..8549a30 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -60,4 +60,5 @@ protected: typedef vector RegexpVector; RegexpVector regexp_in; + friend class Ivy; }; -- cgit v1.1 From e3e468ae17cea2149cf3b06bd64167459adf97c9 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:49 +0000 Subject: Utilisateur : Fcolin Date : 14/02/03 Heure : 18:19 Archivé dans $/Bus/Ivy Commentaire: (vss 7) --- Ivy/IvyApplication.h | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index 8549a30..e39e4a7 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -42,6 +42,7 @@ public: BOOL SameApplication( IvyApplication *app ); UINT remoteService; const char *GetName(void); + inline Ivy *GetBus(void){ return bus;}; int SendMsg( const char *message ); void SendMsg( MsgType msg, int id, const char * arg = NULL); UINT Create(); -- cgit v1.1 From 0c6442aa2e7dbf28f99a76840e005533d0d90b11 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:51 +0000 Subject: Utilisateur : Fcolin Date : 3/03/05 Heure : 14:02 Archivé dans $/Bus/Ivy Commentaire: Passage a la lib PCRE (vss 8) --- Ivy/IvyApplication.h | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index e39e4a7..906e16c 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -6,7 +6,11 @@ #include "BufferedSocket.h" #include "Ivy.h" -class Regexp; +#ifdef USE_PCRE +#include "pcre.h" +#else +#include "Regexp.h" +#endif ///////////////////////////////////////////////////////////////////////////// // IvyApplication command target @@ -58,7 +62,12 @@ protected: bool AppConnectedCallbackCalled; Ivy *bus; /* liste des souscriptions remote */ - typedef vector RegexpVector; +#ifdef USE_PCRE + static const int max_subexp = 200; + typedef vector RegexpVector; +#else + typedef vector RegexpVector; +#endif RegexpVector regexp_in; friend class Ivy; -- cgit v1.1 From f2dfb0633a7ee0cf6b803d3e8575c3710d98f954 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:53 +0000 Subject: Utilisateur : Fcolin Date : 3/03/05 Heure : 14:13 Archivé dans $/Bus/Ivy Commentaire: (vss 9) --- Ivy/IvyApplication.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index 906e16c..61b4432 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -6,6 +6,8 @@ #include "BufferedSocket.h" #include "Ivy.h" +#define USE_PCRE + #ifdef USE_PCRE #include "pcre.h" #else -- cgit v1.1 From 299c93cb71c2b55321a11be3e14800a6be320081 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:55 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 10) --- Ivy/IvyApplication.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index 61b4432..7171fef 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -60,15 +60,15 @@ public: // Implementation protected: - string appname; + ivy::string appname; bool AppConnectedCallbackCalled; Ivy *bus; /* liste des souscriptions remote */ #ifdef USE_PCRE static const int max_subexp = 200; - typedef vector RegexpVector; + typedef ivy::vector RegexpVector; #else - typedef vector RegexpVector; + typedef ivy::vector RegexpVector; #endif RegexpVector regexp_in; -- cgit v1.1 From 23bd912a8e86466c79f2dcbed02f4e34e00aca27 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:57 +0000 Subject: Utilisateur : Fcolin Date : 23/05/06 Heure : 18:18 Archivé dans $/Bus/Ivy Commentaire: Modification protocol UDP (vss 11) --- Ivy/IvyApplication.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index 7171fef..babd82e 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -53,7 +53,7 @@ public: void SendMsg( MsgType msg, int id, const char * arg = NULL); UINT Create(); void OnReceive( char *line ); - void Create( const char * host, UINT &port ); + void Create( const char * host, UINT &port, const char* name ); virtual void OnAccept(int nErrorCode); virtual void OnClose(int nErrorCode); -- cgit v1.1 From f9406cab857e7eb87627c014a880ed859df3bf22 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:00:59 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 10:14 Archivé dans $/Bus/Ivy Commentaire: ajout Binding Callback et SetFilter (vss 12) --- Ivy/IvyApplication.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index babd82e..ffa6ecb 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -64,6 +64,9 @@ protected: bool AppConnectedCallbackCalled; Ivy *bus; /* liste des souscriptions remote */ + /* en clair */ + ivy::vector regexp_str_in; + /* compile */ #ifdef USE_PCRE static const int max_subexp = 200; typedef ivy::vector RegexpVector; -- cgit v1.1 From 224519ededa0125951cf0ca7e13a2b25952321e6 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:01 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 15:54 Archivé dans $/Bus/Ivy Commentaire: Separation module de traitement regexp (vss 13) --- Ivy/IvyApplication.h | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index ffa6ecb..c32ca5f 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -5,14 +5,7 @@ // #include "BufferedSocket.h" #include "Ivy.h" - -#define USE_PCRE - -#ifdef USE_PCRE -#include "pcre.h" -#else -#include "Regexp.h" -#endif +#include "IvyBinding.h" ///////////////////////////////////////////////////////////////////////////// // IvyApplication command target @@ -67,12 +60,7 @@ protected: /* en clair */ ivy::vector regexp_str_in; /* compile */ -#ifdef USE_PCRE - static const int max_subexp = 200; - typedef ivy::vector RegexpVector; -#else - typedef ivy::vector RegexpVector; -#endif + typedef ivy::vector RegexpVector; RegexpVector regexp_in; friend class Ivy; -- cgit v1.1 From fbbba9efa5f7e22b7d6d824b5126af3e20c0479e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:03 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 16:40 Archivé dans $/Bus/Ivy Commentaire: correction bug du a la separation du module regexp transformation des tables de regexp en table de Hash (vss 14) --- Ivy/IvyApplication.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index c32ca5f..64aa49f 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -58,10 +58,10 @@ protected: Ivy *bus; /* liste des souscriptions remote */ /* en clair */ - ivy::vector regexp_str_in; + ivy::map regexp_str_in; /* compile */ - typedef ivy::vector RegexpVector; - RegexpVector regexp_in; + typedef ivy::map Bindings; + Bindings regexp_in; friend class Ivy; }; -- cgit v1.1 From 74967da76a4c47cc6ca1223eb4be776d2a83745a Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:05 +0000 Subject: Utilisateur : Fcolin Date : 1/08/06 Heure : 9:48 Archivé dans $/Bus/Ivy Commentaire: (vss 15) --- Ivy/IvyApplication.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyApplication.h b/Ivy/IvyApplication.h index 64aa49f..7191400 100644 --- a/Ivy/IvyApplication.h +++ b/Ivy/IvyApplication.h @@ -26,7 +26,9 @@ public: EndRegexp, /* end of the regexp list */ StartRegexp, /* debut des expressions */ DirectMsg, /* message direct a destination de l'appli */ - Die /* demande de terminaison de l'appli */ + Die, /* demande de terminaison de l'appli */ + Ping, /* message de controle ivy */ + Pong /* ivy doit renvoyer ce message à la reception d'un ping */ }MsgType; -- cgit v1.1 From 92fc57ceb4fb03e732a2edeef701922a3f570ddc Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:07 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 15:54 Créé Commentaire: Separation module de traitement regexp (vss 1) --- Ivy/IvyBinding.cxx | 189 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 189 insertions(+) create mode 100644 Ivy/IvyBinding.cxx (limited to 'Ivy') diff --git a/Ivy/IvyBinding.cxx b/Ivy/IvyBinding.cxx new file mode 100644 index 0000000..f3000fd --- /dev/null +++ b/Ivy/IvyBinding.cxx @@ -0,0 +1,189 @@ +/* + * Ivy, C++ interface + * + * Copyright (C) 1997-2000 + * Centre d'Études de la Navigation Aérienne + * + * Bind syntax for extracting message comtent + * using regexp or other + * + * Authors: François-Régis Colin + * + * $Id: ivybind.c,v 1.9.2.7 2006/06/01 12:07:17 bustico Exp $ + * + * Please refer to file version.h for the + * copyright notice regarding this software + */ +/* Module de gestion de la syntaxe des messages Ivy */ +#include "IvyStdAfx.h" + +#include "IvyBinding.h" + +static int err_offset; + +#ifdef USE_PCRE + static const char *err_buf; +#else /* we don't USE_PCRE */ + static char err_buf[4096]; +#endif /* USE_PCRE */ + +/* classes de messages emis par l'application utilise pour le filtrage */ +static int messages_classes_count = 0; +static const char **messages_classes = 0; +/* regexp d'extraction du mot clef des regexp client pour le filtrage des regexp , ca va c'est clair ??? */ +static IvyBinding token_extract; + +IvyBinding::IvyBinding() +{ +#ifdef USE_PCRE + regexp = NULL; + inspect = NULL; +#else /* we don't USE_PCRE */ + free( regexp ); +#endif /* USE_PCRE */ + nb_match = 0; +} +IvyBinding::~IvyBinding() +{ +#ifdef USE_PCRE + if (inspect!=NULL) + pcre_free(inspect); + if (regexp!=NULL) + pcre_free(regexp); +#else /* we don't USE_PCRE */ + free( regexp ); +#endif /* USE_PCRE */ +} +bool IvyBinding::Compile( const char * expression, int *erroffset, const char **errmessage ) +{ + bool compile = false; +#ifdef USE_PCRE + regexp = pcre_compile(expression, PCRE_CASELESS, &err_buf, &err_offset, NULL); + if ( regexp != NULL ) + { + this->inspect = pcre_study(regexp,0,&err_buf); + if (err_buf!=NULL) + { + printf("Error studying %s, message: %s\n",expression,err_buf); + } + compile = true; + } + else + { + *erroffset = err_offset; + *errmessage = err_buf; + printf("Error compiling '%s', %s\n", expression, err_buf); + } +#else /* we don't USE_PCRE */ + regex_t regexp; + int reg; + reg = regcomp(®exp, expression, REGCOMP_OPT|REG_EXTENDED); + if ( reg == 0 ) + { + this->next = NULL; + } + else + { + regerror (reg, ®exp, err_buf, sizeof(err_buf) ); + *erroffset = err_offset; + *errmessage = err_buf; + printf("Error compiling '%s', %s\n", expression, err_buf); + } +#endif /* USE_PCRE */ + return compile; +} + + +int IvyBinding::Exec( const char * message ) +{ +#ifdef USE_PCRE + + nb_match = pcre_exec( + regexp, + inspect, + message, + strlen(message), + 0, /* debut */ + 0, /* no other regexp option */ + ovector, + OVECSIZE); + if (nb_match<1) return 0; /* no match */ +#else /* we don't USE_PCRE */ + memset( match, -1, sizeof(match )); /* work around bug !!!*/ + nb_match = regexec (®exp, message, MAX_MSG_FIELDS, match, 0) + if (nb_match == REG_NOMATCH) + return 0; + for ( index = 1; index < MAX_MSG_FIELDS; index++ ) + { + if ( match[i].rm_so != -1 ) + nb_match++; + } +#endif /* USE_PCRE */ + return nb_match; +} + +void IvyBinding::Match( const char *message, int argnum, int *arglen, const char **arg) +{ +#ifdef USE_PCRE + + *arglen = ovector[2*argnum+1]- ovector[2*argnum]; + *arg = message + ovector[2*argnum]; +#else /* we don't USE_PCRE */ + + regmatch_t* p; + + p = &match[argnum+1]; + if ( p->rm_so != -1 ) { + *arglen = p->rm_eo - p->rm_so; + *arg = message + p->rm_so; + } else { // ARG VIDE + *arglen = 0; + *arg = NULL; + } +#endif /* USE_PCRE */ + +} + +//filter Expression Bind +void IvyBinding::SetFilter( int argc, const char **argv) +{ + const char *errbuf; + int erroffset; + + messages_classes_count = argc; + messages_classes = argv; + /* compile the token extraction regexp */ + + if ( !token_extract.Compile("^\\^([a-zA-Z_0-9-]+).*", & erroffset, & errbuf) ) + { + printf("Error compiling Token Extract regexp: %s\n", errbuf); + } +} + +int IvyBinding::Filter(const char *expression) +{ + int i; + int err; + int regexp_ok = 1; /* accepte tout par default */ + int tokenlen; + const char *token; + + if ( *expression =='^' && messages_classes_count !=0 ) + { + regexp_ok = 0; + + /* extract token */ + err = token_extract.Exec( expression ); + if ( err < 1 ) return 1; + token_extract.Match( expression , 1, &tokenlen, &token ); + for ( i = 0 ; i < messages_classes_count; i++ ) + { + if (strncmp( messages_classes[i], token, tokenlen ) == 0) { + return 1; } + // else { + //printf ("DBG> %s eliminé [%s]\n", token, expression); + //} + } + } + return regexp_ok; +} -- cgit v1.1 From 741e6a814b53154a9b55a24de6fcb941af290439 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:09 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 15:54 Créé Commentaire: Separation module de traitement regexp (vss 1) --- Ivy/IvyBinding.h | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 Ivy/IvyBinding.h (limited to 'Ivy') diff --git a/Ivy/IvyBinding.h b/Ivy/IvyBinding.h new file mode 100644 index 0000000..44a87ee --- /dev/null +++ b/Ivy/IvyBinding.h @@ -0,0 +1,58 @@ +/* + * Ivy, C interface + * + * Copyright (C) 1997-2006 + * Centre d'Études de la Navigation Aérienne + * + * Bind syntax for extracting message comtent + * using regexp or other + * + * Authors: François-Régis Colin + * + * $Id: ivybind.h,v 1.5.2.3 2006/04/21 15:51:55 fcolin Exp $ + * + * Please refer to file version.h for the + * copyright notice regarding this software + */ +/* Module de gestion de la syntaxe des messages Ivy */ +#pragma once + +#define USE_PCRE + +#ifdef USE_PCRE +#define OVECSIZE 60 /* must be multiple of 3, for regexp return */ +#include +#else /* we don't USE_PCRE */ +#define MAX_MSG_FIELDS 200 +#include "Regex.h" +#endif /* USE_PCRE */ + +class IvyBinding +{ +public: + /* Creation, Compilation */ + IvyBinding(); + ~IvyBinding(); + + /* Mise en place des Filtrages */ + static void SetFilter( int argc, const char ** argv ); + static int Filter( const char *expression ); + + /* Creation, Compilation */ + bool Compile( const char *expression, int *erroffset, const char **errmessage ); + /* Execution , extraction */ + int Exec( const char * message ); + void Match( const char *message, int argnum, int *arglen, const char **arg ); + +private: +#ifdef USE_PCRE + pcre *regexp; + pcre_extra *inspect; + int nb_match; + int ovector[OVECSIZE]; +#else /* we don't USE_PCRE */ + regex_t regexp; /* la regexp sous forme machine */ + regmatch_t match[MAX_MSG_FIELDS+1]; /* resultat du match */ +#endif /* USE_PCRE */ + +}; \ No newline at end of file -- cgit v1.1 From 321483f0c1433e0b254584db97b3bc6f5ecaa24b Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:11 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/IvyCallback.h | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 Ivy/IvyCallback.h (limited to 'Ivy') diff --git a/Ivy/IvyCallback.h b/Ivy/IvyCallback.h new file mode 100644 index 0000000..4a41b9a --- /dev/null +++ b/Ivy/IvyCallback.h @@ -0,0 +1,83 @@ +// IvyCallback.h : Interface for the IvyMessageCallback Class +// : Interface for the IvyDirectMessageCallback Class +// : Interface for the IvyApplicationCallback Class +// +///////////////////////////////////////////////////////////////////////////// +// Description : +// +///////////////////////////////////////////////////////////////////////////// +// +// $Header: /libIvy/IvyCallback.h 5 16/03/99 10:59 Fcolin $ +// $Modtime: 16/03/99 10:26 $ + +/* -------------------------------------------------------- + * $History: IvyCallback.h $ + * + * ***************** Version 5 ***************** + * User: Fcolin Date: 16/03/99 Time: 10:59 + * Updated in $/libIvy + * + * ***************** Version 4 ***************** + * User: Fcolin Date: 12/03/99 Time: 18:53 + * Updated in $/libIvy + * + * ***************** Version 3 ***************** + * User: Fcolin Date: 12/03/99 Time: 18:16 + * Updated in $/libIvy + * Modif Api Callback + * -------------------------------------------------------- + */ + + +#ifndef IvyCallback_H_ +#define IvyCallback_H_ + +class IvyApplication; + +/* Callback for the normal bus Message */ +/* Callback for the normal bus Message */ +class IvyMessageCallback { +public: + virtual void OnMessage (IvyApplication *app, int argc, const char **argv )=0; +}; +/* template Class Callback for the normal bus Message */ +template class IvyMessageCallbackOf : public IvyMessageCallback { + +protected: + T* Object; + typedef void ( T::*IvyMessageCallback_fun )( IvyApplication *app, int argc, const char **argv ); + IvyMessageCallback_fun MessageCb; + +public: + IvyMessageCallbackOf ( T* o, IvyMessageCallback_fun m_cb ) : Object (o), MessageCb( m_cb ) + { + } + ~IvyMessageCallbackOf () + { + } + void OnMessage (IvyApplication *app, int argc, const char **argv) + { + (Object->*MessageCb) (app, argc, argv); + } +/* raccourci d'ecriture */ +#define BUS_CALLBACK_OF( cl, m ) new IvyMessageCallbackOf( this, m ) +}; +/* Callback for the direct Message */ +class IvyDirectMessageCallback { +public: + virtual void OnDirectMessage (IvyApplication *app, int id, const char *arg ) = 0; +}; + +/* Application Callback */ +class IvyApplicationCallback { +public: + virtual void OnApplicationConnected (IvyApplication *app) = 0; + virtual void OnApplicationDisconnected (IvyApplication *app) = 0; +}; +/* Callback for the die Message */ +class IvyDieCallback { +public: + virtual BOOL OnDie (IvyApplication *app, int id, const char *arg ) = 0; +}; + +#endif /* IvyCallback_H_ */ -- cgit v1.1 From c2898f2c85984b8acdfb7ca987a751f6b69f3b8b Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:13 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:51 Archivé dans $/Ivy Commentaire: bug a la destruction des callbacks --> virtual destructor classe de base (vss 2) --- Ivy/IvyCallback.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyCallback.h b/Ivy/IvyCallback.h index 4a41b9a..bbcaa11 100644 --- a/Ivy/IvyCallback.h +++ b/Ivy/IvyCallback.h @@ -39,6 +39,9 @@ class IvyApplication; class IvyMessageCallback { public: virtual void OnMessage (IvyApplication *app, int argc, const char **argv )=0; + virtual ~IvyMessageCallback() + { + } }; /* template Class Callback for the normal bus Message */ template class IvyMessageCallbackOf : public IvyMessageCallback { -- cgit v1.1 From 53e0d0c2626d919b72f1ba497203bde75fd7d9e1 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:15 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 11:10 Archivé dans $/Ivy (vss 3) --- Ivy/IvyCallback.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyCallback.h b/Ivy/IvyCallback.h index bbcaa11..e311f58 100644 --- a/Ivy/IvyCallback.h +++ b/Ivy/IvyCallback.h @@ -76,11 +76,17 @@ class IvyApplicationCallback { public: virtual void OnApplicationConnected (IvyApplication *app) = 0; virtual void OnApplicationDisconnected (IvyApplication *app) = 0; + virtual ~IvyApplicationCallback() + { + } }; /* Callback for the die Message */ class IvyDieCallback { public: virtual BOOL OnDie (IvyApplication *app, int id, const char *arg ) = 0; + virtual ~IvyDieCallback() + { + } }; #endif /* IvyCallback_H_ */ -- cgit v1.1 From 0b1380fe24ec5ff14212b5dad82b45b1cf663bcc Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:17 +0000 Subject: Utilisateur : Fcolin Date : 14/11/00 Heure : 18:58 Archivé dans $/Ivy (vss 4) --- Ivy/IvyCallback.h | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyCallback.h b/Ivy/IvyCallback.h index e311f58..f1075dc 100644 --- a/Ivy/IvyCallback.h +++ b/Ivy/IvyCallback.h @@ -43,6 +43,25 @@ public: { } }; +class IvyMessageCallbackFunction: public IvyMessageCallback { +public: + typedef void ( *IvyMessageCallback_fun )( IvyApplication *app, int argc, const char **argv ); + IvyMessageCallback_fun MessageCb; + +public: + IvyMessageCallbackFunction ( IvyMessageCallback_fun m_cb ) : MessageCb( m_cb ) + { + } + ~IvyMessageCallbackFunction () + { + } + void OnMessage (IvyApplication *app, int argc, const char **argv) + { + (*MessageCb) (app, argc, argv); + } +/* raccourci d'ecriture */ +#define BUS_CALLBACK( m ) new IvyMessageCallbackFunction( m ) +}; /* template Class Callback for the normal bus Message */ template class IvyMessageCallbackOf : public IvyMessageCallback { -- cgit v1.1 From bb880dc41b1080546a7b50421980c8d6aca96681 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:19 +0000 Subject: Utilisateur : Fcolin Date : 15/11/00 Heure : 18:52 Archivé dans $/Ivy (vss 5) --- Ivy/IvyCallback.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyCallback.h b/Ivy/IvyCallback.h index f1075dc..58eb52e 100644 --- a/Ivy/IvyCallback.h +++ b/Ivy/IvyCallback.h @@ -99,6 +99,16 @@ public: { } }; +class IvyApplicationNullCallback : public IvyApplicationCallback { +public: + virtual void OnApplicationConnected (IvyApplication *app) + {}; + virtual void OnApplicationDisconnected (IvyApplication *app) + {}; + virtual ~IvyApplicationNullCallback() + { + } +}; /* Callback for the die Message */ class IvyDieCallback { public: -- cgit v1.1 From 3f798c133bcf62c1fed88d1beb66c7284285c99c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:21 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 6) --- Ivy/IvyCallback.h | 34 +++------------------------------- 1 file changed, 3 insertions(+), 31 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyCallback.h b/Ivy/IvyCallback.h index 58eb52e..6a877e6 100644 --- a/Ivy/IvyCallback.h +++ b/Ivy/IvyCallback.h @@ -2,40 +2,14 @@ // : Interface for the IvyDirectMessageCallback Class // : Interface for the IvyApplicationCallback Class // -///////////////////////////////////////////////////////////////////////////// -// Description : -// -///////////////////////////////////////////////////////////////////////////// -// -// $Header: /libIvy/IvyCallback.h 5 16/03/99 10:59 Fcolin $ -// $Modtime: 16/03/99 10:26 $ - -/* -------------------------------------------------------- - * $History: IvyCallback.h $ - * - * ***************** Version 5 ***************** - * User: Fcolin Date: 16/03/99 Time: 10:59 - * Updated in $/libIvy - * - * ***************** Version 4 ***************** - * User: Fcolin Date: 12/03/99 Time: 18:53 - * Updated in $/libIvy - * - * ***************** Version 3 ***************** - * User: Fcolin Date: 12/03/99 Time: 18:16 - * Updated in $/libIvy - * Modif Api Callback - * -------------------------------------------------------- - */ -#ifndef IvyCallback_H_ -#define IvyCallback_H_ +#pragma once class IvyApplication; /* Callback for the normal bus Message */ -/* Callback for the normal bus Message */ + class IvyMessageCallback { public: virtual void OnMessage (IvyApplication *app, int argc, const char **argv )=0; @@ -112,10 +86,8 @@ public: /* Callback for the die Message */ class IvyDieCallback { public: - virtual BOOL OnDie (IvyApplication *app, int id, const char *arg ) = 0; + virtual bool OnDie (IvyApplication *app, int id, const char *arg ) = 0; virtual ~IvyDieCallback() { } }; - -#endif /* IvyCallback_H_ */ -- cgit v1.1 From 1172ab63f087da01ee116d155b1b9d3e87bf2ef3 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:23 +0000 Subject: Utilisateur : Fcolin Date : 19/07/01 Heure : 15:22 Archivé dans $/Ivy Commentaire: Ajout callback static pour le CB application (vss 7) --- Ivy/IvyCallback.h | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyCallback.h b/Ivy/IvyCallback.h index 6a877e6..68b286a 100644 --- a/Ivy/IvyCallback.h +++ b/Ivy/IvyCallback.h @@ -65,6 +65,7 @@ public: }; /* Application Callback */ + class IvyApplicationCallback { public: virtual void OnApplicationConnected (IvyApplication *app) = 0; @@ -83,6 +84,33 @@ public: { } }; +// Static function CB +class IvyApplicationCallbackFunction: public IvyApplicationCallback { +public: + typedef void ( *IvyApplicationCallback_fun )( IvyApplication *app ); + IvyApplicationCallback_fun ApplicationConnectedCb; + IvyApplicationCallback_fun ApplicationDisconnectedCb; + +public: + IvyApplicationCallbackFunction ( IvyApplicationCallback_fun con_cb, IvyApplicationCallback_fun disc_cb) + : ApplicationConnectedCb( con_cb ), ApplicationDisconnectedCb( disc_cb ) + { + } + ~IvyApplicationCallbackFunction () + { + } + virtual void OnApplicationConnected (IvyApplication *app) + { + (*ApplicationConnectedCb) (app); + }; + virtual void OnApplicationDisconnected (IvyApplication *app) + { + (*ApplicationDisconnectedCb) (app); + }; + +/* raccourci d'ecriture */ +#define BUS_APPLICATION_CALLBACK( conn, disconn ) new IvyApplicationCallbackFunction( conn, disconn ) +}; /* Callback for the die Message */ class IvyDieCallback { public: -- cgit v1.1 From 9d592353f88d58e0449e8311818ff92185ec5fe0 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:25 +0000 Subject: Utilisateur : Fcolin Date : 25/10/01 Heure : 18:39 Archivé dans $/Ivy (vss 8) --- Ivy/IvyCallback.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyCallback.h b/Ivy/IvyCallback.h index 68b286a..25368f0 100644 --- a/Ivy/IvyCallback.h +++ b/Ivy/IvyCallback.h @@ -19,22 +19,24 @@ public: }; class IvyMessageCallbackFunction: public IvyMessageCallback { public: - typedef void ( *IvyMessageCallback_fun )( IvyApplication *app, int argc, const char **argv ); + typedef void ( *IvyMessageCallback_fun )( IvyApplication *app, void *user_data, int argc, const char **argv ); IvyMessageCallback_fun MessageCb; + void *data; public: - IvyMessageCallbackFunction ( IvyMessageCallback_fun m_cb ) : MessageCb( m_cb ) + IvyMessageCallbackFunction ( IvyMessageCallback_fun m_cb, void *udata = NULL ) : MessageCb( m_cb ) { + data = udata; } ~IvyMessageCallbackFunction () { } void OnMessage (IvyApplication *app, int argc, const char **argv) { - (*MessageCb) (app, argc, argv); + (*MessageCb) (app, data, argc, argv); } /* raccourci d'ecriture */ -#define BUS_CALLBACK( m ) new IvyMessageCallbackFunction( m ) +#define BUS_CALLBACK( m , d ) new IvyMessageCallbackFunction( m, d ) }; /* template Class Callback for the normal bus Message */ template class IvyMessageCallbackOf : public IvyMessageCallback { -- cgit v1.1 From cca8702ee446dd87d4bca25dfa1e5b199649f490 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:27 +0000 Subject: Utilisateur : Fcolin Date : 16/11/05 Heure : 9:54 Archivé dans $/Bus/Ivy Commentaire: 64 bits ports (vss 9) --- Ivy/IvyCallback.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyCallback.h b/Ivy/IvyCallback.h index 25368f0..78aff80 100644 --- a/Ivy/IvyCallback.h +++ b/Ivy/IvyCallback.h @@ -58,7 +58,7 @@ public: (Object->*MessageCb) (app, argc, argv); } /* raccourci d'ecriture */ -#define BUS_CALLBACK_OF( cl, m ) new IvyMessageCallbackOf( this, m ) +#define BUS_CALLBACK_OF( cl, m ) new IvyMessageCallbackOf( this, &cl::m ) }; /* Callback for the direct Message */ class IvyDirectMessageCallback { -- cgit v1.1 From 528bf5ef59ac20c903cdef0b646f41f62564f6c7 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:29 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 10:14 Archivé dans $/Bus/Ivy Commentaire: ajout Binding Callback et SetFilter (vss 10) --- Ivy/IvyCallback.h | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 59 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyCallback.h b/Ivy/IvyCallback.h index 78aff80..ede0ef4 100644 --- a/Ivy/IvyCallback.h +++ b/Ivy/IvyCallback.h @@ -103,16 +103,73 @@ public: } virtual void OnApplicationConnected (IvyApplication *app) { - (*ApplicationConnectedCb) (app); + if ( ApplicationConnectedCb ) (*ApplicationConnectedCb) (app); }; virtual void OnApplicationDisconnected (IvyApplication *app) { - (*ApplicationDisconnectedCb) (app); + if ( ApplicationDisconnectedCb ) (*ApplicationDisconnectedCb) (app); }; /* raccourci d'ecriture */ #define BUS_APPLICATION_CALLBACK( conn, disconn ) new IvyApplicationCallbackFunction( conn, disconn ) }; + +/* Binding Callback */ + +class IvyBindingCallback { +public: + virtual void OnAddBind (IvyApplication *app, int id, const char * regexp) = 0; + virtual void OnRemoveBind (IvyApplication *app, int id, const char * regexp) = 0; + virtual void OnFilterBind (IvyApplication *app, int id, const char * regexp) = 0; + virtual ~IvyBindingCallback() + { + } +}; +class IvyBindingNullCallback : public IvyBindingCallback { +public: + virtual void OnAddBind (IvyApplication *app, int id, const char * regexp) + {}; + virtual void OnRemoveBind (IvyApplication *app, int id, const char * regexp) + {}; + virtual void OnFilterBind (IvyApplication *app, int id, const char * regexp) + {}; + virtual ~IvyBindingNullCallback() + { + } +}; +// Static function CB +class IvyBindingCallbackFunction: public IvyBindingCallback { +public: + typedef void ( *IvyBindingCallback_fun )( IvyApplication *app, int id, const char * regexp ); + IvyBindingCallback_fun BindingAddCb; + IvyBindingCallback_fun BindingRemoveCb; + IvyBindingCallback_fun BindingFilterCb; + +public: + IvyBindingCallbackFunction ( IvyBindingCallback_fun add_cb, IvyBindingCallback_fun remove_cb, IvyBindingCallback_fun filter_cb ) + : BindingAddCb( add_cb ), BindingRemoveCb( remove_cb ), BindingFilterCb( filter_cb ) + { + } + ~IvyBindingCallbackFunction () + { + } + virtual void OnAddBind (IvyApplication *app, int id, const char * regexp) + { + if(BindingAddCb) (*BindingAddCb) (app, id, regexp); + }; + virtual void OnRemoveBind (IvyApplication *app, int id, const char * regexp) + { + if (BindingRemoveCb) (*BindingRemoveCb) (app, id, regexp); + }; + virtual void OnFilterBind (IvyApplication *app, int id, const char * regexp) + { + if(BindingFilterCb ) (*BindingFilterCb) (app, id, regexp); + }; + +/* raccourci d'ecriture */ +#define BUS_BINDING_CALLBACK( add, remove, filter ) new IvyBindingCallbackFunction( add, remove, filter ) +}; + /* Callback for the die Message */ class IvyDieCallback { public: -- cgit v1.1 From 8a274412cccd5237e03481028bcfab96a5e85070 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:31 +0000 Subject: Utilisateur : Fcolin Date : 18/10/01 Heure : 18:24 Créé (vss 1) --- Ivy/IvyCbindings.cxx | 73 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 Ivy/IvyCbindings.cxx (limited to 'Ivy') diff --git a/Ivy/IvyCbindings.cxx b/Ivy/IvyCbindings.cxx new file mode 100644 index 0000000..de87db4 --- /dev/null +++ b/Ivy/IvyCbindings.cxx @@ -0,0 +1,73 @@ + +#include "stdafx.h" + +#include "Ivy.h" +#include "IvyApplication.h" + +/* filtrage des regexps */ +void IvyClasses( int argc, const char **argv) +{ +} + +void IvyInit( + const char *AppName, /* nom de l'application */ + const char *ready, /* ready Message peut etre NULL */ + IvyApplicationCallback callback, /* callback appele sur connection deconnection d'une appli */ + void *data, /* user data passe au callback */ + IvyDieCallback die_callback, /* last change callback before die */ + void *die_data ) /* user data */ +{ +} +void IvyStart (const char*) +{ +} +void IvyStop () +{ +} + +/* query sur les applications connectees */ +char *IvyGetApplicationName( IvyClientPtr app ) +{ +} +char *IvyGetApplicationHost( IvyClientPtr app ) +{ +} +IvyClientPtr IvyGetApplication( char *name ) +{ +} +char *IvyGetApplicationList() +{ +} +char **IvyGetApplicationMessages( IvyClientPtr app) +{ +} + +MsgRcvPtr IvyBindMsg( MsgCallback callback, void *user_data, const char *fmt_regexp, ... ) +{ +} +void IvyUnbindMsg( MsgRcvPtr id ) +{ +} + +/* emission d'un message d'erreur */ +void IvySendError( IvyClientPtr app, int id, const char *fmt, ... ) +{ +} + +/* emmission d'un message die pour terminer l'application */ +void IvySendDieMsg( IvyClientPtr app ) +{ +} + +/* emission d'un message retourne le nb effectivement emis */ + +int IvySendMsg( const char *fmt_message, ... ) +{ +} + +void IvyBindDirectMsg( MsgDirectCallback callback, void *user_data) +{ +} +void IvySendDirectMsg( IvyClientPtr app, int id, char *msg ) +{ +} -- cgit v1.1 From 55eaa424173f390b66f3eb392c48f069c357533b Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:33 +0000 Subject: Utilisateur : Fcolin Date : 25/10/01 Heure : 18:39 Archivé dans $/Ivy (vss 2) --- Ivy/IvyCbindings.cxx | 76 +++++++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 64 insertions(+), 12 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyCbindings.cxx b/Ivy/IvyCbindings.cxx index de87db4..07becfc 100644 --- a/Ivy/IvyCbindings.cxx +++ b/Ivy/IvyCbindings.cxx @@ -1,71 +1,123 @@ #include "stdafx.h" - +#include #include "Ivy.h" #include "IvyApplication.h" -/* filtrage des regexps */ -void IvyClasses( int argc, const char **argv) +#include "IvyCbindings.h" + +static Ivy *bus = NULL; + +// application callback wrappers +IvyCApplicationCallback app_cb = NULL; +void * app_user_data = NULL; +void app_conn( IvyApplication *app ) +{ + (*app_cb)(app, app_user_data, IvyApplicationConnected ); +} +void app_discon( IvyApplication *app ) { + (*app_cb)(app, app_user_data, IvyApplicationDisconnected ); } void IvyInit( const char *AppName, /* nom de l'application */ const char *ready, /* ready Message peut etre NULL */ - IvyApplicationCallback callback, /* callback appele sur connection deconnection d'une appli */ + IvyCApplicationCallback callback, /* callback appele sur connection deconnection d'une appli */ void *data, /* user data passe au callback */ - IvyDieCallback die_callback, /* last change callback before die */ + IvyCDieCallback die_callback, /* last change callback before die */ void *die_data ) /* user data */ { + bus = new Ivy(AppName, ready, BUS_APPLICATION_CALLBACK(app_conn,app_discon) ); +} +/* filtrage des regexps */ +void IvyClasses( int argc, const char **argv) +{ + bus->Classes( argc, argv ); } -void IvyStart (const char*) + +void IvyStart (const char* domain) { + bus->start(domain); } void IvyStop () { + bus->stop(); } /* query sur les applications connectees */ -char *IvyGetApplicationName( IvyClientPtr app ) +const char *IvyGetApplicationName( IvyClientPtr app ) { + return ((IvyApplication*)app)->GetName(); } -char *IvyGetApplicationHost( IvyClientPtr app ) +const char *IvyGetApplicationHost( IvyClientPtr app ) { + string host; + UINT port; + ((IvyApplication*)app)->GetPeerName(host,port); + return host.c_str(); } IvyClientPtr IvyGetApplication( char *name ) { + return NULL; } -char *IvyGetApplicationList() +const char *IvyGetApplicationList() { + return "Not yiet implemented"; } -char **IvyGetApplicationMessages( IvyClientPtr app) +const char **IvyGetApplicationMessages( IvyClientPtr app) { + return NULL; } -MsgRcvPtr IvyBindMsg( MsgCallback callback, void *user_data, const char *fmt_regexp, ... ) +MsgRcvPtr IvyBindMsg( IvyCMsgCallback callback, void *user_data, const char *fmt_regexp, ... ) { + int count; + char buf_regexp[2048]; + va_list args; + va_start( args, fmt_regexp ); + vsprintf( buf_regexp, fmt_regexp, args ); + count = bus->BindMsg(buf_regexp, BUS_CALLBACK( ((IvyMessageCallbackFunction::IvyMessageCallback_fun)callback), user_data ) ); + va_end( args ); + return count; } void IvyUnbindMsg( MsgRcvPtr id ) { + bus->UnbindMsg( id ); } /* emission d'un message d'erreur */ void IvySendError( IvyClientPtr app, int id, const char *fmt, ... ) { + char buf[2048]; + va_list args; + va_start( args, fmt ); + vsprintf( buf, fmt, args ); + ((IvyApplication*)app)->SendMsg( IvyApplication::Error, id, buf ); + va_end( args ); } /* emmission d'un message die pour terminer l'application */ void IvySendDieMsg( IvyClientPtr app ) { + ((IvyApplication*)app)->SendMsg( IvyApplication::Die, 0 ); } /* emission d'un message retourne le nb effectivement emis */ int IvySendMsg( const char *fmt_message, ... ) { + int count; + char buf[2048]; + va_list args; + va_start( args, fmt_message ); + vsprintf( buf, fmt_message, args ); + count = bus->SendMsg(buf); + va_end( args ); + return count; } -void IvyBindDirectMsg( MsgDirectCallback callback, void *user_data) +void IvyBindDirectMsg( IvyCMsgDirectCallback callback, void *user_data) { } void IvySendDirectMsg( IvyClientPtr app, int id, char *msg ) -- cgit v1.1 From 28cc6cec36580bba460de5f77700c994a0b04a7f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:35 +0000 Subject: Utilisateur : Fcolin Date : 24/05/05 Heure : 11:29 Archivé dans $/Bus/Ivy Commentaire: Ajout MainLoop binding Ivy C (vss 3) --- Ivy/IvyCbindings.cxx | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyCbindings.cxx b/Ivy/IvyCbindings.cxx index 07becfc..18d5268 100644 --- a/Ivy/IvyCbindings.cxx +++ b/Ivy/IvyCbindings.cxx @@ -123,3 +123,7 @@ void IvyBindDirectMsg( IvyCMsgDirectCallback callback, void *user_data) void IvySendDirectMsg( IvyClientPtr app, int id, char *msg ) { } +void IvyMainLoop( void(*hook)(void) ) +{ + Sleep( INFINITE ); +} -- cgit v1.1 From b3c991e52707bf1447d1c63b5b6a78fa300753e3 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:37 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:45 Archivé dans $/Bus/Ivy Commentaire: (vss 4) --- Ivy/IvyCbindings.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyCbindings.cxx b/Ivy/IvyCbindings.cxx index 18d5268..9ab5efb 100644 --- a/Ivy/IvyCbindings.cxx +++ b/Ivy/IvyCbindings.cxx @@ -1,5 +1,5 @@ -#include "stdafx.h" +#include "IvyStdAfx.h" #include #include "Ivy.h" #include "IvyApplication.h" @@ -76,7 +76,7 @@ MsgRcvPtr IvyBindMsg( IvyCMsgCallback callback, void *user_data, const char *fmt char buf_regexp[2048]; va_list args; va_start( args, fmt_regexp ); - vsprintf( buf_regexp, fmt_regexp, args ); + _vsnprintf( buf_regexp, sizeof(buf_regexp), fmt_regexp, args ); count = bus->BindMsg(buf_regexp, BUS_CALLBACK( ((IvyMessageCallbackFunction::IvyMessageCallback_fun)callback), user_data ) ); va_end( args ); return count; @@ -92,7 +92,7 @@ void IvySendError( IvyClientPtr app, int id, const char *fmt, ... ) char buf[2048]; va_list args; va_start( args, fmt ); - vsprintf( buf, fmt, args ); + _vsnprintf( buf, sizeof(buf), fmt, args ); ((IvyApplication*)app)->SendMsg( IvyApplication::Error, id, buf ); va_end( args ); } @@ -111,7 +111,7 @@ int IvySendMsg( const char *fmt_message, ... ) char buf[2048]; va_list args; va_start( args, fmt_message ); - vsprintf( buf, fmt_message, args ); + _vsnprintf( buf, sizeof(buf), fmt_message, args ); count = bus->SendMsg(buf); va_end( args ); return count; -- cgit v1.1 From e63bd03a298522ad519fd2070faad9d6a36ed403 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:39 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 5) --- Ivy/IvyCbindings.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyCbindings.cxx b/Ivy/IvyCbindings.cxx index 9ab5efb..9a188ab 100644 --- a/Ivy/IvyCbindings.cxx +++ b/Ivy/IvyCbindings.cxx @@ -52,7 +52,7 @@ const char *IvyGetApplicationName( IvyClientPtr app ) } const char *IvyGetApplicationHost( IvyClientPtr app ) { - string host; + ivy::string host; UINT port; ((IvyApplication*)app)->GetPeerName(host,port); return host.c_str(); -- cgit v1.1 From f06851fa71982d57d257119435876aa48bc6ab86 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:41 +0000 Subject: Utilisateur : Fcolin Date : 16/11/05 Heure : 9:54 Archivé dans $/Bus/Ivy Commentaire: 64 bits ports (vss 6) --- Ivy/IvyCbindings.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyCbindings.cxx b/Ivy/IvyCbindings.cxx index 9a188ab..7f11339 100644 --- a/Ivy/IvyCbindings.cxx +++ b/Ivy/IvyCbindings.cxx @@ -76,7 +76,7 @@ MsgRcvPtr IvyBindMsg( IvyCMsgCallback callback, void *user_data, const char *fmt char buf_regexp[2048]; va_list args; va_start( args, fmt_regexp ); - _vsnprintf( buf_regexp, sizeof(buf_regexp), fmt_regexp, args ); + _vsnprintf_s( buf_regexp, sizeof(buf_regexp), sizeof(buf_regexp)-1, fmt_regexp, args ); count = bus->BindMsg(buf_regexp, BUS_CALLBACK( ((IvyMessageCallbackFunction::IvyMessageCallback_fun)callback), user_data ) ); va_end( args ); return count; @@ -92,7 +92,7 @@ void IvySendError( IvyClientPtr app, int id, const char *fmt, ... ) char buf[2048]; va_list args; va_start( args, fmt ); - _vsnprintf( buf, sizeof(buf), fmt, args ); + _vsnprintf_s( buf, sizeof(buf), sizeof(buf)-1, fmt, args ); ((IvyApplication*)app)->SendMsg( IvyApplication::Error, id, buf ); va_end( args ); } @@ -111,7 +111,7 @@ int IvySendMsg( const char *fmt_message, ... ) char buf[2048]; va_list args; va_start( args, fmt_message ); - _vsnprintf( buf, sizeof(buf), fmt_message, args ); + _vsnprintf_s( buf, sizeof(buf), sizeof(buf)-1, fmt_message, args ); count = bus->SendMsg(buf); va_end( args ); return count; -- cgit v1.1 From 93e316c3985bd8327b64dba94791ac3efa63ed4b Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:43 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 10:14 Archivé dans $/Bus/Ivy Commentaire: ajout Binding Callback et SetFilter (vss 7) --- Ivy/IvyCbindings.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyCbindings.cxx b/Ivy/IvyCbindings.cxx index 7f11339..8876bbf 100644 --- a/Ivy/IvyCbindings.cxx +++ b/Ivy/IvyCbindings.cxx @@ -31,9 +31,9 @@ void IvyInit( bus = new Ivy(AppName, ready, BUS_APPLICATION_CALLBACK(app_conn,app_discon) ); } /* filtrage des regexps */ -void IvyClasses( int argc, const char **argv) +void IvySetFilter( int argc, const char **argv) { - bus->Classes( argc, argv ); + bus->SetFilter( argc, argv ); } void IvyStart (const char* domain) -- cgit v1.1 From 5104844b75345754efccd3e57ee0115a43412293 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:45 +0000 Subject: Utilisateur : Fcolin Date : 18/10/01 Heure : 18:13 Créé (vss 1) --- Ivy/IvyCbindings.h | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 Ivy/IvyCbindings.h (limited to 'Ivy') diff --git a/Ivy/IvyCbindings.h b/Ivy/IvyCbindings.h new file mode 100644 index 0000000..e69de29 -- cgit v1.1 From a812f0d63a9aea44f8f4ee50aba809759dffb1c3 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:47 +0000 Subject: Utilisateur : Fcolin Date : 25/10/01 Heure : 18:39 Archivé dans $/Ivy (vss 2) --- Ivy/IvyCbindings.h | 107 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 107 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyCbindings.h b/Ivy/IvyCbindings.h index e69de29..fb12f55 100644 --- a/Ivy/IvyCbindings.h +++ b/Ivy/IvyCbindings.h @@ -0,0 +1,107 @@ +/* + * Ivy, C interface + * + * Copyright (C) 1997-2000 + * Centre d'Études de la Navigation Aérienne + * + * Main functions + * + * Authors: François-Régis Colin + * Stéphane Chatty + * + * $Id: ivy.h,v 1.8 2000/08/07 11:29:29 sc Exp $ + * + * Please refer to file version.h for the + * copyright notice regarding this software + */ + +#ifndef IVY_C_BINDINGS_H +#define IVY_C_BINDINGS_H + + +#ifdef __cplusplus +extern "C" { +#endif + +#ifdef WIN32 +#ifdef IVY_EXPORTS +#define DLL_EXPORT _declspec(dllexport) +#else +#pragma comment(lib,"Ivy.LIB" ) +#define DLL_EXPORT /*_declspec(dllimport)*/ +#endif +#endif + + +/* numero par default du bus */ + +#define DEFAULT_BUS 2010 + +typedef void * Channel ; +typedef int TimerId; + +typedef void * IvyClientPtr; + +typedef enum { IvyApplicationConnected, IvyApplicationDisconnected } IvyApplicationEvent; + +extern void IvyDefaultApplicationCallback( IvyClientPtr app, void *user_data, IvyApplicationEvent event ) ; + +/* callback callback appele sur connexion deconnexion d'une appli */ +typedef void (*IvyCApplicationCallback)( IvyClientPtr app, void *user_data, IvyApplicationEvent event ) ; + +/* callback appele sur reception de die */ +typedef void (*IvyCDieCallback)( IvyClientPtr app, void *user_data, int id ) ; + +/* callback appele sur reception de messages normaux */ +typedef void (*IvyCMsgCallback)( IvyClientPtr app, void *user_data, int argc, const char **argv ) ; + +/* callback appele sur reception de messages directs */ +typedef void (*IvyCMsgDirectCallback)( IvyClientPtr app, void *user_data, int id, char *msg ) ; + +/* identifiant d'une expression reguliere ( Bind/Unbind ) */ +typedef int MsgRcvPtr; + +/* filtrage des regexps */ +DLL_EXPORT void IvyClasses( int argc, const char **argv); + +DLL_EXPORT void IvyInit( + const char *AppName, /* nom de l'application */ + const char *ready, /* ready Message peut etre NULL */ + IvyCApplicationCallback callback, /* callback appele sur connection deconnection d'une appli */ + void *data, /* user data passe au callback */ + IvyCDieCallback die_callback, /* last change callback before die */ + void *die_data ); /* user data */ + +DLL_EXPORT void IvyStart (const char*); +DLL_EXPORT void IvyStop (); + +/* query sur les applications connectees */ +DLL_EXPORT const char *IvyGetApplicationName( IvyClientPtr app ); +DLL_EXPORT const char *IvyGetApplicationHost( IvyClientPtr app ); +DLL_EXPORT IvyClientPtr IvyGetApplication( char *name ); +DLL_EXPORT const char *IvyGetApplicationList(); +DLL_EXPORT const char **IvyGetApplicationMessages( IvyClientPtr app); /* demande de reception d'un message */ + +DLL_EXPORT MsgRcvPtr IvyBindMsg( IvyCMsgCallback callback, void *user_data, const char *fmt_regexp, ... ); /* avec sprintf prealable */ +DLL_EXPORT void IvyUnbindMsg( MsgRcvPtr id ); + +/* emission d'un message d'erreur */ +DLL_EXPORT void IvySendError( IvyClientPtr app, int id, const char *fmt, ... ); + +/* emmission d'un message die pour terminer l'application */ +DLL_EXPORT void IvySendDieMsg( IvyClientPtr app ); + +/* emission d'un message retourne le nb effectivement emis */ + +DLL_EXPORT int IvySendMsg( const char *fmt_message, ... ); /* avec sprintf prealable */ + +/* Message Direct Inter-application */ + +DLL_EXPORT void IvyBindDirectMsg( IvyCMsgDirectCallback callback, void *user_data); +DLL_EXPORT void IvySendDirectMsg( IvyClientPtr app, int id, char *msg ); + +#ifdef __cplusplus +} +#endif + +#endif -- cgit v1.1 From febbe67c93a0b700a5f79e8f181cf029667d0e51 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:49 +0000 Subject: Utilisateur : Fcolin Date : 24/05/05 Heure : 11:29 Archivé dans $/Bus/Ivy Commentaire: Ajout MainLoop binding Ivy C (vss 3) --- Ivy/IvyCbindings.h | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/IvyCbindings.h b/Ivy/IvyCbindings.h index fb12f55..08e8548 100644 --- a/Ivy/IvyCbindings.h +++ b/Ivy/IvyCbindings.h @@ -99,6 +99,7 @@ DLL_EXPORT int IvySendMsg( const char *fmt_message, ... ); /* avec sprintf prea DLL_EXPORT void IvyBindDirectMsg( IvyCMsgDirectCallback callback, void *user_data); DLL_EXPORT void IvySendDirectMsg( IvyClientPtr app, int id, char *msg ); +DLL_EXPORT void IvyMainLoop( void(*hook)(void) ); #ifdef __cplusplus } -- cgit v1.1 From 6a70ff0dd344091a4568edfd25f993d8c3e4a543 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:51 +0000 Subject: Utilisateur : Fcolin Date : 21/11/05 Heure : 12:53 Archivé dans $/Bus/Ivy Commentaire: remplacement event =>evt ( event mot clé reservé ) (vss 4) --- Ivy/IvyCbindings.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyCbindings.h b/Ivy/IvyCbindings.h index 08e8548..38ccfd6 100644 --- a/Ivy/IvyCbindings.h +++ b/Ivy/IvyCbindings.h @@ -44,10 +44,10 @@ typedef void * IvyClientPtr; typedef enum { IvyApplicationConnected, IvyApplicationDisconnected } IvyApplicationEvent; -extern void IvyDefaultApplicationCallback( IvyClientPtr app, void *user_data, IvyApplicationEvent event ) ; +extern void IvyDefaultApplicationCallback( IvyClientPtr app, void *user_data, IvyApplicationEvent evt ) ; /* callback callback appele sur connexion deconnexion d'une appli */ -typedef void (*IvyCApplicationCallback)( IvyClientPtr app, void *user_data, IvyApplicationEvent event ) ; +typedef void (*IvyCApplicationCallback)( IvyClientPtr app, void *user_data, IvyApplicationEvent evt ) ; /* callback appele sur reception de die */ typedef void (*IvyCDieCallback)( IvyClientPtr app, void *user_data, int id ) ; -- cgit v1.1 From fac0389f44d31bbe4f0f5a3021fc15ffa7e3c66a Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:53 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/IvyDllMain.cpp | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 Ivy/IvyDllMain.cpp (limited to 'Ivy') diff --git a/Ivy/IvyDllMain.cpp b/Ivy/IvyDllMain.cpp new file mode 100644 index 0000000..ac1a854 --- /dev/null +++ b/Ivy/IvyDllMain.cpp @@ -0,0 +1,29 @@ +// libIvy.cpp : Defines the initialization routines for the DLL. +// + +#include "stdafx.h" + + +extern "C" int APIENTRY +DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved) +{ + // Remove this if you use lpReserved + UNREFERENCED_PARAMETER(lpReserved); + + if (dwReason == DLL_PROCESS_ATTACH) + { + TRACE("LIBIVY.DLL Initializing!\n"); + + // Extension DLL one-time initialization + //if (WSAInit) + // return 0; + + + } + else if (dwReason == DLL_PROCESS_DETACH) + { + TRACE("LIBIVY.DLL Terminating!\n"); + // Terminate the library before destructors are called + } + return 1; // ok +} -- cgit v1.1 From 08ce8432585e4d71a31fd09a66d543f79d011471 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:55 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:40 Archivé dans $/Ivy Commentaire: Init dll socket dans DLLMain (vss 2) --- Ivy/IvyDllMain.cpp | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyDllMain.cpp b/Ivy/IvyDllMain.cpp index ac1a854..c49283a 100644 --- a/Ivy/IvyDllMain.cpp +++ b/Ivy/IvyDllMain.cpp @@ -12,18 +12,31 @@ DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved) if (dwReason == DLL_PROCESS_ATTACH) { - TRACE("LIBIVY.DLL Initializing!\n"); + TRACE("IVY.DLL Initializing!\n"); // Extension DLL one-time initialization - //if (WSAInit) - // return 0; + + WORD wVersionRequested; + WSADATA wsaData; + int err; + + wVersionRequested = MAKEWORD( 2, 2 ); + + err = WSAStartup( wVersionRequested, &wsaData ); + if ( err != 0 ) { + /* Tell the user that we could not find a usable */ + /* WinSock DLL. */ + return 0; + } + } else if (dwReason == DLL_PROCESS_DETACH) { - TRACE("LIBIVY.DLL Terminating!\n"); + TRACE("IVY.DLL Terminating!\n"); // Terminate the library before destructors are called + WSACleanup(); } return 1; // ok } -- cgit v1.1 From 32e665d555a00010b60bb3efc6f2676b0eca7194 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:57 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 3) --- Ivy/IvyDllMain.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyDllMain.cpp b/Ivy/IvyDllMain.cpp index c49283a..a94616f 100644 --- a/Ivy/IvyDllMain.cpp +++ b/Ivy/IvyDllMain.cpp @@ -3,9 +3,9 @@ #include "stdafx.h" - -extern "C" int APIENTRY -DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved) +BOOL APIENTRY DllMain(HANDLE hInstance, + DWORD dwReason, + LPVOID lpReserved) { // Remove this if you use lpReserved UNREFERENCED_PARAMETER(lpReserved); -- cgit v1.1 From ae6b836b82f8ddc8f49e9ba6edf5b17ec478ceee Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:01:59 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 4) --- Ivy/IvyDllMain.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyDllMain.cpp b/Ivy/IvyDllMain.cpp index a94616f..554df47 100644 --- a/Ivy/IvyDllMain.cpp +++ b/Ivy/IvyDllMain.cpp @@ -20,7 +20,7 @@ BOOL APIENTRY DllMain(HANDLE hInstance, WSADATA wsaData; int err; - wVersionRequested = MAKEWORD( 2, 2 ); + wVersionRequested = MAKEWORD( 2, 0 ); err = WSAStartup( wVersionRequested, &wsaData ); if ( err != 0 ) { -- cgit v1.1 From b31c22ea4e3df8700dad80e8bc2496bcf63ceb58 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:01 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:45 Archivé dans $/Bus/Ivy Commentaire: (vss 5) --- Ivy/IvyDllMain.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyDllMain.cpp b/Ivy/IvyDllMain.cpp index 554df47..e8c13f4 100644 --- a/Ivy/IvyDllMain.cpp +++ b/Ivy/IvyDllMain.cpp @@ -1,7 +1,7 @@ // libIvy.cpp : Defines the initialization routines for the DLL. // -#include "stdafx.h" +#include "IvyStdAfx.h" BOOL APIENTRY DllMain(HANDLE hInstance, DWORD dwReason, -- cgit v1.1 From b860a1ff0cec2953f7a893c496f6a20356038251 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:09 +0000 Subject: Utilisateur : Fcolin Date : 20/01/06 Heure : 13:50 Créé Commentaire: (vss 1) --- Ivy/IvyLib/IvyLib.vdproj | 242 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 242 insertions(+) create mode 100644 Ivy/IvyLib/IvyLib.vdproj (limited to 'Ivy') diff --git a/Ivy/IvyLib/IvyLib.vdproj b/Ivy/IvyLib/IvyLib.vdproj new file mode 100644 index 0000000..2a92dde --- /dev/null +++ b/Ivy/IvyLib/IvyLib.vdproj @@ -0,0 +1,242 @@ +"DeployProject" +{ +"VSVersion" = "3:800" +"ProjectType" = "8:{06A35CCD-C46D-44D5-987B-CF40FF872267}" +"IsWebType" = "8:FALSE" +"ProjectName" = "8:IvyLib" +"LanguageId" = "3:1033" +"CodePage" = "3:1252" +"UILanguageId" = "3:1033" +"SccProjectName" = "8:SAK" +"SccLocalPath" = "8:SAK" +"SccAuxPath" = "8:SAK" +"SccProvider" = "8:SAK" + "Hierarchy" + { + "Entry" + { + "MsmKey" = "8:_66D910CBB02B47569794CF954A72E057" + "OwnerKey" = "8:_UNDEFINED" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_DE30DB02DD7494AFFBB32B50F67B491E" + "OwnerKey" = "8:_66D910CBB02B47569794CF954A72E057" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_EF9BC5D6F4274E54867D4FB7F7A33653" + "OwnerKey" = "8:_UNDEFINED" + "MsmSig" = "8:_UNDEFINED" + } + } + "Configurations" + { + "Debug" + { + "DisplayName" = "8:Debug" + "IsDebugOnly" = "11:TRUE" + "IsReleaseOnly" = "11:FALSE" + "OutputFilename" = "8:Debug\\IvyLib.msm" + "PackageFilesAs" = "3:2" + "PackageFileSize" = "3:-2147483648" + "CabType" = "3:1" + "Compression" = "3:2" + "SignOutput" = "11:FALSE" + "CertificateFile" = "8:" + "PrivateKeyFile" = "8:" + "TimeStampServer" = "8:" + "InstallerBootstrapper" = "3:1" + } + "Release" + { + "DisplayName" = "8:Release" + "IsDebugOnly" = "11:FALSE" + "IsReleaseOnly" = "11:TRUE" + "OutputFilename" = "8:Release\\IvyLib.msm" + "PackageFilesAs" = "3:2" + "PackageFileSize" = "3:-2147483648" + "CabType" = "3:1" + "Compression" = "3:2" + "SignOutput" = "11:FALSE" + "CertificateFile" = "8:" + "PrivateKeyFile" = "8:" + "TimeStampServer" = "8:" + "InstallerBootstrapper" = "3:1" + } + } + "Deployable" + { + "CustomAction" + { + } + "DefaultFeature" + { + "Name" = "8:DefaultFeature" + "Title" = "8:" + "Description" = "8:" + } + "File" + { + "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_DE30DB02DD7494AFFBB32B50F67B491E" + { + "SourcePath" = "8:WSOCK32.dll" + "TargetName" = "8:WSOCK32.dll" + "Tag" = "8:" + "Folder" = "8:_E128D81775304F09A5707F244264031A" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:TRUE" + "IsDependency" = "11:TRUE" + "IsolateTo" = "8:" + } + } + "FileType" + { + } + "Folder" + { + "{F4FE1E22-A4D2-4EE8-9259-29A1CE8BB2FF}:_E128D81775304F09A5707F244264031A" + { + "DefaultLocation" = "8:[TARGETDIR]" + "DisplayName" = "8:Module Retargetable Folder" + "Description" = "8:" + "Name" = "8:Module Retargetable Folder" + "AlwaysCreate" = "11:FALSE" + "Condition" = "8:" + "Transitive" = "11:TRUE" + "Property" = "8:NEWRETARGETABLEPROPERTY1" + "Folders" + { + } + } + } + "Sequences" + { + } + "MergeModule" + { + } + "Module" + { + "ModuleSignature" = "8:MergeModule.B704211C29924E868D1D16832CA83D91" + "Version" = "8:1.0.0.0" + "Title" = "8:IvyLib" + "Subject" = "8:" + "Author" = "8:DTI/SDER" + "Keywords" = "8:" + "Comments" = "8:" + "SearchPath" = "8:" + "UseSystemSearchPath" = "11:TRUE" + "TargetPlatform" = "3:0" + "PreBuildEvent" = "8:" + "PostBuildEvent" = "8:" + "RunPostBuildEvent" = "3:0" + } + "ProjectOutput" + { + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_66D910CBB02B47569794CF954A72E057" + { + "SourcePath" = "8:..\\..\\release\\Ivy.dll" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_E128D81775304F09A5707F244264031A" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:Built" + "OutputProjectGuid" = "8:{9BD87B7A-517E-4900-B3EA-A358885CD876}" + "ShowKeyOutput" = "11:FALSE" + "ExcludeFilters" + { + } + } + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_EF9BC5D6F4274E54867D4FB7F7A33653" + { + "SourcePath" = "8:..\\..\\release\\pcre.dll" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_E128D81775304F09A5707F244264031A" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:FALSE" + "IsolateTo" = "8:" + "ProjectOutputGroupRegister" = "3:1" + "OutputConfiguration" = "8:" + "OutputGroupCanonicalName" = "8:Built" + "OutputProjectGuid" = "8:{D79FC143-498E-4342-B2C7-BDAD1B8D0E6B}" + "ShowKeyOutput" = "11:FALSE" + "ExcludeFilters" + { + } + } + } + "Registry" + { + "HKLM" + { + "Keys" + { + } + } + "HKCU" + { + "Keys" + { + } + } + "HKCR" + { + "Keys" + { + } + } + "HKU" + { + "Keys" + { + } + } + "HKPU" + { + "Keys" + { + } + } + } + "Shortcut" + { + } + } +} -- cgit v1.1 From 8a7bd665b5a7f583651535bf670e66913cd95bc9 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:10 +0000 Subject: Utilisateur : Fcolin Date : 1/08/06 Heure : 13:14 Archivé dans $/Bus/Ivy/IvyLib Commentaire: (vss 2) --- Ivy/IvyLib/IvyLib.vdproj | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyLib/IvyLib.vdproj b/Ivy/IvyLib/IvyLib.vdproj index 2a92dde..e8a78e1 100644 --- a/Ivy/IvyLib/IvyLib.vdproj +++ b/Ivy/IvyLib/IvyLib.vdproj @@ -3,7 +3,7 @@ "VSVersion" = "3:800" "ProjectType" = "8:{06A35CCD-C46D-44D5-987B-CF40FF872267}" "IsWebType" = "8:FALSE" -"ProjectName" = "8:IvyLib" +"ProjectName" = "8:InstallIvyLib" "LanguageId" = "3:1033" "CodePage" = "3:1252" "UILanguageId" = "3:1033" @@ -49,6 +49,17 @@ "PrivateKeyFile" = "8:" "TimeStampServer" = "8:" "InstallerBootstrapper" = "3:1" + "BootstrapperCfg:{63ACBE69-63AA-4F98-B2B6-99F9E24495F2}" + { + "Enabled" = "11:FALSE" + "PromptEnabled" = "11:TRUE" + "PrerequisitesLocation" = "2:1" + "Url" = "8:" + "ComponentsUrl" = "8:" + "Items" + { + } + } } "Release" { @@ -65,6 +76,17 @@ "PrivateKeyFile" = "8:" "TimeStampServer" = "8:" "InstallerBootstrapper" = "3:1" + "BootstrapperCfg:{63ACBE69-63AA-4F98-B2B6-99F9E24495F2}" + { + "Enabled" = "11:FALSE" + "PromptEnabled" = "11:TRUE" + "PrerequisitesLocation" = "2:1" + "Url" = "8:" + "ComponentsUrl" = "8:" + "Items" + { + } + } } } "Deployable" @@ -134,13 +156,13 @@ "Title" = "8:IvyLib" "Subject" = "8:" "Author" = "8:DTI/SDER" - "Keywords" = "8:" + "Keywords" = "8:Ivy" "Comments" = "8:" "SearchPath" = "8:" "UseSystemSearchPath" = "11:TRUE" "TargetPlatform" = "3:0" "PreBuildEvent" = "8:" - "PostBuildEvent" = "8:" + "PostBuildEvent" = "8:\"$(ProjectDir)..\\..\\UpdateIvyWeb.bat\" \"$(BuiltOuputPath)\"" "RunPostBuildEvent" = "3:0" } "ProjectOutput" -- cgit v1.1 From de9934763ae11ba972c1ec9ba408ac75255f1fae Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:12 +0000 Subject: Utilisateur : Fcolin Date : 20/01/06 Heure : 13:50 Créé Commentaire: (vss 1) --- Ivy/IvyLib/IvyLib.vdproj.vspscc | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 Ivy/IvyLib/IvyLib.vdproj.vspscc (limited to 'Ivy') diff --git a/Ivy/IvyLib/IvyLib.vdproj.vspscc b/Ivy/IvyLib/IvyLib.vdproj.vspscc new file mode 100644 index 0000000..1cf11d0 --- /dev/null +++ b/Ivy/IvyLib/IvyLib.vdproj.vspscc @@ -0,0 +1,10 @@ +"" +{ +"FILE_VERSION" = "9237" +"ENLISTMENT_CHOICE" = "NEVER" +"PROJECT_FILE_RELATIVE_PATH" = "relative:Ivy\\IvyLib" +"NUMBER_OF_EXCLUDED_FILES" = "0" +"ORIGINAL_PROJECT_FILE_PATH" = "" +"NUMBER_OF_NESTED_PROJECTS" = "0" +"SOURCE_CONTROL_SETTINGS_PROVIDER" = "PROVIDER" +} -- cgit v1.1 From a3053cc5def34cd48b8fb0015ffb245b3e1d53dc Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:14 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/IvyStdAfx.cpp | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 Ivy/IvyStdAfx.cpp (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.cpp b/Ivy/IvyStdAfx.cpp new file mode 100644 index 0000000..5feeaf4 --- /dev/null +++ b/Ivy/IvyStdAfx.cpp @@ -0,0 +1,18 @@ +// stdafx.cpp : source file that includes just the standard includes +// libIvy.pch will be the pre-compiled header +// stdafx.obj will contain the pre-compiled type information + +#include "stdafx.h" + +#include + +void DebugTrace ( const char *fmt , ... ) +{ + char buffer[4096]; + va_list args; + + va_start( args, fmt ); + vsprintf( buffer, fmt, args ); + va_end( args ); + OutputDebugString( buffer ); +} \ No newline at end of file -- cgit v1.1 From 681c212050da8dfafefeaec363dd054cca914819 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:16 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 2) --- Ivy/IvyStdAfx.cpp | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.cpp b/Ivy/IvyStdAfx.cpp index 5feeaf4..fa5d17b 100644 --- a/Ivy/IvyStdAfx.cpp +++ b/Ivy/IvyStdAfx.cpp @@ -11,8 +11,21 @@ void DebugTrace ( const char *fmt , ... ) char buffer[4096]; va_list args; - va_start( args, fmt ); + va_start( args, fmt ); vsprintf( buffer, fmt, args ); va_end( args ); - OutputDebugString( buffer ); -} \ No newline at end of file +// OutputDebugStringA( buffer ); +} +#ifdef WIN32 +#ifdef _DEBUG +#include +void* __cdecl operator new(size_t nSize, const char * lpszFileName, int nLine) + { + return ::operator new(nSize, _NORMAL_BLOCK, lpszFileName, nLine); + } +void __cdecl operator delete(void *p, const char * lpszFileName, int nLine) + { + ::operator delete(p, _NORMAL_BLOCK, lpszFileName, nLine); + } +#endif +#endif -- cgit v1.1 From 1dae5ed0fca313c60b4c387dbbb54dd5820fcb0f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:18 +0000 Subject: Utilisateur : Fcolin Date : 14/02/01 Heure : 18:47 Archivé dans $/Ivy (vss 3) --- Ivy/IvyStdAfx.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.cpp b/Ivy/IvyStdAfx.cpp index fa5d17b..a7b35f2 100644 --- a/Ivy/IvyStdAfx.cpp +++ b/Ivy/IvyStdAfx.cpp @@ -14,7 +14,7 @@ void DebugTrace ( const char *fmt , ... ) va_start( args, fmt ); vsprintf( buffer, fmt, args ); va_end( args ); -// OutputDebugStringA( buffer ); + OutputDebugStringA( buffer ); } #ifdef WIN32 #ifdef _DEBUG -- cgit v1.1 From 122b2805e10d4e28521fc7f695685b665d36bfe0 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:20 +0000 Subject: Utilisateur : Fcolin Date : 19/02/01 Heure : 10:37 Archivé dans $/Ivy (vss 4) --- Ivy/IvyStdAfx.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.cpp b/Ivy/IvyStdAfx.cpp index a7b35f2..8da5a6e 100644 --- a/Ivy/IvyStdAfx.cpp +++ b/Ivy/IvyStdAfx.cpp @@ -9,12 +9,21 @@ void DebugTrace ( const char *fmt , ... ) { char buffer[4096]; +#ifdef UNDER_CE + TCHAR CEBuffer[4096]; +#endif va_list args; va_start( args, fmt ); vsprintf( buffer, fmt, args ); va_end( args ); - OutputDebugStringA( buffer ); +#ifdef UNDER_CE + MultiByteToWideChar( CP_ACP, MB_PRECOMPOSED, buffer, -1, CEBuffer, 4096 ); + + OutputDebugString( CEBuffer ); +#else + OutputDebugString( buffer ); +#endif } #ifdef WIN32 #ifdef _DEBUG -- cgit v1.1 From 3cbb903ca0a1c671838bec02f8fff48ceff60e5d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:22 +0000 Subject: Utilisateur : Fcolin Date : 20/02/01 Heure : 10:27 Archivé dans $/Ivy (vss 5) --- Ivy/IvyStdAfx.cpp | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.cpp b/Ivy/IvyStdAfx.cpp index 8da5a6e..41fc8a6 100644 --- a/Ivy/IvyStdAfx.cpp +++ b/Ivy/IvyStdAfx.cpp @@ -25,16 +25,3 @@ void DebugTrace ( const char *fmt , ... ) OutputDebugString( buffer ); #endif } -#ifdef WIN32 -#ifdef _DEBUG -#include -void* __cdecl operator new(size_t nSize, const char * lpszFileName, int nLine) - { - return ::operator new(nSize, _NORMAL_BLOCK, lpszFileName, nLine); - } -void __cdecl operator delete(void *p, const char * lpszFileName, int nLine) - { - ::operator delete(p, _NORMAL_BLOCK, lpszFileName, nLine); - } -#endif -#endif -- cgit v1.1 From a8d96166e058d988bba3fd12d66d73ff08c98f14 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:24 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:45 Archivé dans $/Bus/Ivy Commentaire: (vss 6) --- Ivy/IvyStdAfx.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.cpp b/Ivy/IvyStdAfx.cpp index 41fc8a6..0d1d4b4 100644 --- a/Ivy/IvyStdAfx.cpp +++ b/Ivy/IvyStdAfx.cpp @@ -2,7 +2,7 @@ // libIvy.pch will be the pre-compiled header // stdafx.obj will contain the pre-compiled type information -#include "stdafx.h" +#include "IvyStdAfx.h" #include @@ -15,7 +15,7 @@ void DebugTrace ( const char *fmt , ... ) va_list args; va_start( args, fmt ); - vsprintf( buffer, fmt, args ); + _vsnprintf( buffer, sizeof(buffer), fmt, args ); va_end( args ); #ifdef UNDER_CE MultiByteToWideChar( CP_ACP, MB_PRECOMPOSED, buffer, -1, CEBuffer, 4096 ); -- cgit v1.1 From 0732202b512ed4093004ec6fbb6caff87492d231 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:26 +0000 Subject: Utilisateur : Fcolin Date : 16/11/05 Heure : 9:54 Archivé dans $/Bus/Ivy Commentaire: 64 bits ports (vss 7) --- Ivy/IvyStdAfx.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.cpp b/Ivy/IvyStdAfx.cpp index 0d1d4b4..2fe8012 100644 --- a/Ivy/IvyStdAfx.cpp +++ b/Ivy/IvyStdAfx.cpp @@ -15,7 +15,7 @@ void DebugTrace ( const char *fmt , ... ) va_list args; va_start( args, fmt ); - _vsnprintf( buffer, sizeof(buffer), fmt, args ); + _vsnprintf_s( buffer, sizeof(buffer), sizeof(buffer)-1, fmt, args ); va_end( args ); #ifdef UNDER_CE MultiByteToWideChar( CP_ACP, MB_PRECOMPOSED, buffer, -1, CEBuffer, 4096 ); -- cgit v1.1 From a8fd499421c677da8c2704a6c885da9ad744257e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:28 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/IvyStdAfx.h | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 Ivy/IvyStdAfx.h (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h new file mode 100644 index 0000000..60ed24d --- /dev/null +++ b/Ivy/IvyStdAfx.h @@ -0,0 +1,44 @@ +// stdafx.h : include file for standard system include files, +// or project specific include files that are used frequently, but +// are changed infrequently +// + +#if !defined(AFX_STDAFX_H__EE0269AE_DB02_11D2_89CA_00A0245B298A__INCLUDED_) +#define AFX_STDAFX_H__EE0269AE_DB02_11D2_89CA_00A0245B298A__INCLUDED_ + +#if _MSC_VER > 1000 +#pragma once +#endif // _MSC_VER > 1000 +#ifdef WIN32 + +#pragma warning (disable : 4786) +#pragma warning( disable : 4275 ) // non dll-interface class 'X' used as base for dll-interface class 'Y' +#pragma warning( disable : 4251 ) // 'm' : class 'X' needs to have dll-interface to be used by clients of class 'Y' + +#endif + +#include +#include +#include +#include + +#include +#include +#include + +using namespace std; + +// Debugging function + +#ifndef TRACE +#ifdef WIN32 +void DebugTrace ( const char *fmt , ... ); +#define TRACE DebugTrace +#else +#define TRACE printf +#endif +#endif +//{{AFX_INSERT_LOCATION}} +// Microsoft Visual C++ will insert additional declarations immediately before the previous line. + +#endif // !defined(AFX_STDAFX_H__EE0269AE_DB02_11D2_89CA_00A0245B298A__INCLUDED_) -- cgit v1.1 From 8a81bd5fd18cd5021df69fc3a5913b3e9443a37e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:30 +0000 Subject: Utilisateur : Fcolin Date : 29/06/00 Heure : 15:59 Archivé dans $/Ivy Commentaire: Version multicast (vss 2) --- Ivy/IvyStdAfx.h | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index 60ed24d..88ef83d 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -20,8 +20,28 @@ #include #include #include -#include +#include +// Some definition missing from winsock2 +/* + * Options for use with [gs]etsockopt at the IP level. + */ +#define IP_OPTIONS 1 /* set/get IP per-packet options */ +#define IP_MULTICAST_IF 2 /* set/get IP multicast interface */ +#define IP_MULTICAST_TTL 3 /* set/get IP multicast timetolive */ +#define IP_MULTICAST_LOOP 4 /* set/get IP multicast loopback */ +#define IP_ADD_MEMBERSHIP 5 /* add an IP group membership */ +#define IP_DROP_MEMBERSHIP 6 /* drop an IP group membership */ +#define IP_TTL 7 /* set/get IP Time To Live */ +#define IP_TOS 8 /* set/get IP Type Of Service */ +#define IP_DONTFRAGMENT 9 /* set/get IP Don't Fragment flag */ +/* + * Argument structure for IP_ADD_MEMBERSHIP and IP_DROP_MEMBERSHIP. + */ +struct ip_mreq { + struct in_addr imr_multiaddr; /* IP multicast address of group */ + struct in_addr imr_interface; /* local IP address of interface */ +}; #include #include #include -- cgit v1.1 From 347befcaeb7050e7dbad27bfea53f04ad15355df Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:32 +0000 Subject: Utilisateur : Fcolin Date : 20/07/00 Heure : 10:57 Archivé dans $/Ivy (vss 3) --- Ivy/IvyStdAfx.h | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index 88ef83d..622609f 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -44,6 +44,7 @@ struct ip_mreq { }; #include #include +#include #include using namespace std; -- cgit v1.1 From c47735cf1ac762f9fb9e2aa9a197b636b671c8b4 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:34 +0000 Subject: Utilisateur : Fcolin Date : 23/01/01 Heure : 13:12 Archivé dans $/Ivy Commentaire: remove 'using name space std;' (vss 4) --- Ivy/IvyStdAfx.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index 622609f..a036dd3 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -47,9 +47,9 @@ struct ip_mreq { #include #include -using namespace std; +typedef std::string String; -// Debugging function +//using namespace std; #ifndef TRACE #ifdef WIN32 -- cgit v1.1 From 32cf69c6042f917b72f853460022aedacdc0fbfb Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:36 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 5) --- Ivy/IvyStdAfx.h | 44 ++++++++++++++++++++++++++++++++------------ 1 file changed, 32 insertions(+), 12 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index a036dd3..4a795f4 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -3,25 +3,24 @@ // are changed infrequently // -#if !defined(AFX_STDAFX_H__EE0269AE_DB02_11D2_89CA_00A0245B298A__INCLUDED_) -#define AFX_STDAFX_H__EE0269AE_DB02_11D2_89CA_00A0245B298A__INCLUDED_ - -#if _MSC_VER > 1000 #pragma once -#endif // _MSC_VER > 1000 + #ifdef WIN32 #pragma warning (disable : 4786) #pragma warning( disable : 4275 ) // non dll-interface class 'X' used as base for dll-interface class 'Y' #pragma warning( disable : 4251 ) // 'm' : class 'X' needs to have dll-interface to be used by clients of class 'Y' +#include #endif +#include #include #include -#include +#include -#include +//#include +#ifdef _WINSOCK2API_ // Some definition missing from winsock2 /* * Options for use with [gs]etsockopt at the IP level. @@ -42,24 +41,45 @@ struct ip_mreq { struct in_addr imr_multiaddr; /* IP multicast address of group */ struct in_addr imr_interface; /* local IP address of interface */ }; +#endif + +#ifndef _WIN32_WCE +#define STL +#endif +#ifdef STL #include #include #include #include -typedef std::string String; +using std::string; +using std::vector; +using std::map; +using std::list; +#else +#include "DataTypes.h" +#endif //using namespace std; #ifndef TRACE #ifdef WIN32 + void DebugTrace ( const char *fmt , ... ); #define TRACE DebugTrace #else #define TRACE printf #endif #endif -//{{AFX_INSERT_LOCATION}} -// Microsoft Visual C++ will insert additional declarations immediately before the previous line. - -#endif // !defined(AFX_STDAFX_H__EE0269AE_DB02_11D2_89CA_00A0245B298A__INCLUDED_) +#ifndef ASSERT +#ifdef WIN32 +#define ASSERT(expr) \ + do { \ + if (!(expr) && (1 == _CrtDbgReport( \ + _CRT_ASSERT, __FILE__, __LINE__, "Ivy", #expr))) \ + _CrtDbgBreak(); \ + } while (0) +#else +#define ASSERT printf +#endif +#endif -- cgit v1.1 From 96a3abc0ff921996eb9c68b3b57104d8aae3e43e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:38 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 6) --- Ivy/IvyStdAfx.h | 70 ++++++++++++++++++++++++++++++++++++++++----------------- 1 file changed, 49 insertions(+), 21 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index 4a795f4..ca8c507 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -5,19 +5,17 @@ #pragma once -#ifdef WIN32 - -#pragma warning (disable : 4786) -#pragma warning( disable : 4275 ) // non dll-interface class 'X' used as base for dll-interface class 'Y' -#pragma warning( disable : 4251 ) // 'm' : class 'X' needs to have dll-interface to be used by clients of class 'Y' -#include +#if defined( WIN32 ) || defined( UNDER_CE ) +#pragma warning( disable : 4786 ) // identifier was truncated to '255' characters in the debug information +#pragma warning( disable : 4275 ) // non dll-interface class 'X' used as base for dll-interface class 'Y' +#pragma warning( disable : 4251 ) // 'm' : class 'X' needs to have dll-interface to be used by clients of class 'Y' #endif -#include +#include #include #include -#include +#include //#include #ifdef _WINSOCK2API_ @@ -43,8 +41,12 @@ struct ip_mreq { }; #endif -#ifndef _WIN32_WCE -#define STL +#ifndef IN_CLASSD +#define IN_CLASSD(i) (((long)(i) & 0xf0000000) == 0xe0000000) +#endif + +#ifndef UNDER_CE +//#define STL #endif #ifdef STL #include @@ -54,32 +56,58 @@ struct ip_mreq { using std::string; using std::vector; -using std::map; using std::list; #else #include "DataTypes.h" #endif -//using namespace std; -#ifndef TRACE + #ifdef WIN32 +#ifndef TRACE void DebugTrace ( const char *fmt , ... ); #define TRACE DebugTrace -#else -#define TRACE printf #endif + +#ifndef ASSERT +#define ASSERT(expr) \ + do { \ + if (! (expr) ) \ + {\ + TRACE( "Assert (%s) at %s:%d\n", #expr, __FILE__ , __LINE__ ); \ + DebugBreak(); \ + }\ + } while (0) +#endif +#elif defined( _WIN32_WCE ) + + +#ifndef TRACE +void DebugTrace ( const char *fmt , ... ); +#define TRACE DebugTrace #endif + #ifndef ASSERT -#ifdef WIN32 #define ASSERT(expr) \ do { \ - if (!(expr) && (1 == _CrtDbgReport( \ - _CRT_ASSERT, __FILE__, __LINE__, "Ivy", #expr))) \ - _CrtDbgBreak(); \ + if (! (expr) ) \ + {\ + TRACE( "Assert (%s) failed in file %s at line %d\r\n", #expr, __FILE__ , __LINE__ ); \ + DebugBreak(); \ + }\ } while (0) -#else -#define ASSERT printf #endif + +#else +#include +#define TRACE printf +#define ASSERT(expr) assert( expr ) #endif + +#ifdef WIN32 + +void* __cdecl operator new(size_t nSize, const char * lpszFileName, int nLine); +void __cdecl operator delete(void *p, const char * lpszFileName, int nLine); + +#endif \ No newline at end of file -- cgit v1.1 From 2fa8fb886639e88ea8a2fead0991da38689aaf2b Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:40 +0000 Subject: Utilisateur : Fcolin Date : 14/02/01 Heure : 18:47 Archivé dans $/Ivy (vss 7) --- Ivy/IvyStdAfx.h | 1 - 1 file changed, 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index ca8c507..c9ed653 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -51,7 +51,6 @@ struct ip_mreq { #ifdef STL #include #include -#include #include using std::string; -- cgit v1.1 From 7960d649075ff2ee8d74ff8d9f8745408f52b9b4 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:42 +0000 Subject: Utilisateur : Fcolin Date : 19/02/01 Heure : 10:37 Archivé dans $/Ivy (vss 8) --- Ivy/IvyStdAfx.h | 24 +++++------------------- 1 file changed, 5 insertions(+), 19 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index c9ed653..b197ad7 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -62,37 +62,23 @@ using std::list; -#ifdef WIN32 +#ifdef WIN32 #ifndef TRACE void DebugTrace ( const char *fmt , ... ); #define TRACE DebugTrace #endif -#ifndef ASSERT -#define ASSERT(expr) \ - do { \ - if (! (expr) ) \ - {\ - TRACE( "Assert (%s) at %s:%d\n", #expr, __FILE__ , __LINE__ ); \ - DebugBreak(); \ - }\ - } while (0) -#endif -#elif defined( _WIN32_WCE ) - - -#ifndef TRACE -void DebugTrace ( const char *fmt , ... ); -#define TRACE DebugTrace -#endif +#if defined(_WIN32_WCE) +#undef ASSERT +#endif // _WIN32_WCE #ifndef ASSERT #define ASSERT(expr) \ do { \ if (! (expr) ) \ {\ - TRACE( "Assert (%s) failed in file %s at line %d\r\n", #expr, __FILE__ , __LINE__ ); \ + TRACE( "Assert (%s) failed in file %s at line %d\r\n", TEXT(#expr), __FILE__ , __LINE__ ); \ DebugBreak(); \ }\ } while (0) -- cgit v1.1 From 0932419feeffc111b28762c490adfd6054f372e3 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:44 +0000 Subject: Utilisateur : Fcolin Date : 20/02/01 Heure : 10:27 Archivé dans $/Ivy (vss 9) --- Ivy/IvyStdAfx.h | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index b197ad7..9bb291c 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -46,7 +46,7 @@ struct ip_mreq { #endif #ifndef UNDER_CE -//#define STL +#define STL #endif #ifdef STL #include @@ -90,9 +90,16 @@ void DebugTrace ( const char *fmt , ... ); #define ASSERT(expr) assert( expr ) #endif -#ifdef WIN32 +#if defined( WIN32 ) && (!defined(UNDER_CE)) +#include -void* __cdecl operator new(size_t nSize, const char * lpszFileName, int nLine); -void __cdecl operator delete(void *p, const char * lpszFileName, int nLine); +inline void* __cdecl operator new(size_t nSize, const char * lpszFileName, int nLine) + { + return ::operator new(nSize, _NORMAL_BLOCK, lpszFileName, nLine); + } +inline void __cdecl operator delete(void *p, const char * lpszFileName, int nLine) + { + ::operator delete(p, _NORMAL_BLOCK, lpszFileName, nLine); + } -#endif \ No newline at end of file +#endif -- cgit v1.1 From a793429d90412587a0e7b493d177272774fd81c1 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:46 +0000 Subject: Utilisateur : Fcolin Date : 20/02/01 Heure : 10:52 Archivé dans $/Ivy (vss 10) --- Ivy/IvyStdAfx.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index 9bb291c..e335332 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -91,8 +91,10 @@ void DebugTrace ( const char *fmt , ... ); #endif #if defined( WIN32 ) && (!defined(UNDER_CE)) -#include +#include +#ifndef DEBUG_NEW_OP +#define DEBUG_NEW_OP inline void* __cdecl operator new(size_t nSize, const char * lpszFileName, int nLine) { return ::operator new(nSize, _NORMAL_BLOCK, lpszFileName, nLine); @@ -101,5 +103,6 @@ inline void __cdecl operator delete(void *p, const char * lpszFileName, int nLin { ::operator delete(p, _NORMAL_BLOCK, lpszFileName, nLine); } +#endif #endif -- cgit v1.1 From ed57724939eb298af5ed2d810937acd18e1418ce Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:48 +0000 Subject: Utilisateur : Fcolin Date : 23/05/01 Heure : 10:25 Archivé dans $/Ivy (vss 11) --- Ivy/IvyStdAfx.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index e335332..df0561a 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -90,7 +90,7 @@ void DebugTrace ( const char *fmt , ... ); #define ASSERT(expr) assert( expr ) #endif -#if defined( WIN32 ) && (!defined(UNDER_CE)) +#if defined( WIN32 ) && (!defined(UNDER_CE)) && (!defined(_AFX)) #include #ifndef DEBUG_NEW_OP -- cgit v1.1 From e5bc8ece1d671160e129161ade3a29d9be37d9f5 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:50 +0000 Subject: Utilisateur : Fcolin Date : 16/07/01 Heure : 11:47 Archivé dans $/Ivy (vss 12) --- Ivy/IvyStdAfx.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index df0561a..82df2b2 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -90,7 +90,7 @@ void DebugTrace ( const char *fmt , ... ); #define ASSERT(expr) assert( expr ) #endif -#if defined( WIN32 ) && (!defined(UNDER_CE)) && (!defined(_AFX)) +#if defined( WIN32 ) && defined( _DEBUG ) && (!defined(UNDER_CE)) && (!defined(_AFX)) #include #ifndef DEBUG_NEW_OP -- cgit v1.1 From 9fb98a3d1a6a0798ac11f0695075b93e82102377 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:52 +0000 Subject: Utilisateur : Fcolin Date : 17/07/01 Heure : 18:25 Archivé dans $/Ivy (vss 13) --- Ivy/IvyStdAfx.h | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index 82df2b2..8dd1de2 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -92,17 +92,5 @@ void DebugTrace ( const char *fmt , ... ); #if defined( WIN32 ) && defined( _DEBUG ) && (!defined(UNDER_CE)) && (!defined(_AFX)) -#include -#ifndef DEBUG_NEW_OP -#define DEBUG_NEW_OP -inline void* __cdecl operator new(size_t nSize, const char * lpszFileName, int nLine) - { - return ::operator new(nSize, _NORMAL_BLOCK, lpszFileName, nLine); - } -inline void __cdecl operator delete(void *p, const char * lpszFileName, int nLine) - { - ::operator delete(p, _NORMAL_BLOCK, lpszFileName, nLine); - } -#endif #endif -- cgit v1.1 From e47da423a8f6187cf616e5db6884c97d886021a9 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:54 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:45 Archivé dans $/Bus/Ivy Commentaire: (vss 14) --- Ivy/IvyStdAfx.h | 19 ------------------- 1 file changed, 19 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index 8dd1de2..13d097c 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -45,22 +45,7 @@ struct ip_mreq { #define IN_CLASSD(i) (((long)(i) & 0xf0000000) == 0xe0000000) #endif -#ifndef UNDER_CE -#define STL -#endif -#ifdef STL -#include -#include -#include - -using std::string; -using std::vector; -using std::list; -#else #include "DataTypes.h" -#endif - - #ifdef WIN32 @@ -90,7 +75,3 @@ void DebugTrace ( const char *fmt , ... ); #define ASSERT(expr) assert( expr ) #endif -#if defined( WIN32 ) && defined( _DEBUG ) && (!defined(UNDER_CE)) && (!defined(_AFX)) - - -#endif -- cgit v1.1 From 6eb1ac4e3bbaed76c1ff39f793a54a0c2330812c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:56 +0000 Subject: Utilisateur : Fcolin Date : 18/11/05 Heure : 11:46 Archivé dans $/Bus/Ivy Commentaire: repassage a la STL et correction bug multithread (vss 15) --- Ivy/IvyStdAfx.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index 13d097c..1c0821b 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -45,8 +45,21 @@ struct ip_mreq { #define IN_CLASSD(i) (((long)(i) & 0xf0000000) == 0xe0000000) #endif +#ifdef IVY_USE_OWN_DATATYPES + #include "DataTypes.h" +#else + +#include +#include +#include + +namespace ivy = std; + +#endif + + #ifdef WIN32 #ifndef TRACE -- cgit v1.1 From 215bf25b659764e7064259f329a6663dc625f80b Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:02:58 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 16:40 Archivé dans $/Bus/Ivy Commentaire: correction bug du a la separation du module regexp transformation des tables de regexp en table de Hash (vss 16) --- Ivy/IvyStdAfx.h | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/IvyStdAfx.h b/Ivy/IvyStdAfx.h index 1c0821b..58a16bb 100644 --- a/Ivy/IvyStdAfx.h +++ b/Ivy/IvyStdAfx.h @@ -54,6 +54,7 @@ struct ip_mreq { #include #include #include +#include namespace ivy = std; -- cgit v1.1 From bf1538cd4977d8278f2dc22a796a1192c8794783 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:00 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/IvySynchroWnd.cxx | 158 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 158 insertions(+) create mode 100644 Ivy/IvySynchroWnd.cxx (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx new file mode 100644 index 0000000..297c64e --- /dev/null +++ b/Ivy/IvySynchroWnd.cxx @@ -0,0 +1,158 @@ +// SynchroWnd.cpp : implementation file +// + +#include "stdafx.h" + +#include "IvySynchroWnd.h" + + +#define WM_MESSAGE_CB WM_USER + 1001 +#define WM_APPCONNECTED_CB WM_USER + 1002 +#define WM_APPDISCONNECTED_CB WM_USER + 1003 + +IvySynchroWnd* IvySynchronousCallback::m_synchro = NULL; +IvySynchroWnd* IvySynchroWnd::m_synchro = NULL; + +///////////////////////////////////////////////////////////////////////////// +// IvySynchroWnd + +IvySynchroWnd::IvySynchroWnd() +{ + m_hWnd = NULL; + m_synchro = this; + + WNDCLASS wc; + + // Fill in the window class structure with parameters + // that describe the main window. + + wc.style = 0; // noredraw if size changes + wc.lpfnWndProc = WindowProc; // points to window procedure + wc.cbClsExtra = 0; // no extra class memory + wc.cbWndExtra = 0; // no extra window memory + wc.hInstance = 0; // handle to instance + wc.hIcon = NULL; // predefined app. icon + wc.hCursor = NULL; // predefined arrow + wc.hbrBackground = 0; // white background brush + wc.lpszMenuName = NULL; // no menu + wc.lpszClassName = "IvySynchroClass"; // name of window class + + // Register the window class. + + if ( ! RegisterClass(&wc) ) + { + TRACE("Warning: unable to create Ivy Synchro notify window!\n"); + //AfxThrowResourceException(); + } + + // Create the syncrho window. + m_hWnd = CreateWindowEx(0, "IvySynchroClass","Ivy Synchro Notification Sink", + WS_OVERLAPPED, 0, 0, 0, 0, NULL , NULL, NULL, NULL); + if (!m_hWnd) + { + TRACE("Warning: unable to create Ivy Synchro notify window!\n"); + //AfxThrowResourceException(); + } + +} +IvySynchroWnd::~IvySynchroWnd() +{ +} + + +LRESULT CALLBACK IvySynchroWnd::WindowProc( HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam ) +{ + switch ( uMsg ) + { + case WM_MESSAGE_CB: + m_synchro->OnMessageCB( wParam, lParam ); + break; + case WM_APPCONNECTED_CB: + m_synchro->OnApplicationConnectedCB( wParam, lParam ); + break; + case WM_APPDISCONNECTED_CB: + m_synchro->OnApplicationDisconnectedCB( wParam, lParam ); + break; + + // + // Process other messages. + // + + default: + return DefWindowProc(hwnd, uMsg, wParam, lParam); + } + return 0; +} + + + + +///////////////////////////////////////////////////////////////////////////// +// IvySynchroWnd message handlers + + +LRESULT IvySynchroWnd::OnMessageCB(WPARAM wParam, LPARAM lParam) +{ + IvySynchronousMessageCallback *param = ( IvySynchronousMessageCallback * ) lParam; +// TRACE( "IvySynchroWnd::OnMessageCB msg count %d\n",wParam); + param->target->OnMessage( param->app, param->argc, (const char **) param->argv ); + for( int i = 0; i < param->argc ; i++ ) + free( param->argv[i] ); // allocated with strdup + delete param->argv; // allocated with new + delete param; + return 0L; +} +LRESULT IvySynchroWnd::OnApplicationConnectedCB(WPARAM wParam, LPARAM lParam) +{ + IvySynchronousApplicationCallback *param = ( IvySynchronousApplicationCallback * ) lParam; +// TRACE( "IvySynchroWnd::OnSynchroNotify End Synchro\n"); + param->target->OnApplicationConnected( param->app ); + delete param; + return 0L; +} +LRESULT IvySynchroWnd::OnApplicationDisconnectedCB(WPARAM wParam, LPARAM lParam) +{ + IvySynchronousApplicationCallback *param = ( IvySynchronousApplicationCallback * ) lParam; +// TRACE( "IvySynchroWnd::OnSynchroNotify End Synchro\n"); + param->target->OnApplicationDisconnected( param->app ); + delete param; + return 0L; +} +// +// +IvySynchronousMessageCallback::IvySynchronousMessageCallback( IvyMessageCallback *cb ) +{ + target = cb; +} +void IvySynchronousMessageCallback::OnMessage(IvyApplication *app, int argc, const char **argv ) +{ + static int msg_count = 0; + // duplicate on the Message Queue + IvySynchronousMessageCallback *param = new IvySynchronousMessageCallback(target); + param->app = app; + param->argc = argc; + param->argv = new char*[argc]; + for( int i = 0; i < argc ; i++ ) + param->argv[i] = strdup( argv[i]); +// TRACE( "IvySynchronousMessageCallback::OnMessage msg count %d\n",wParam); + assert(PostMessage(m_synchro->m_hWnd, WM_MESSAGE_CB, msg_count++, (LPARAM)param )); + +} +IvySynchronousApplicationCallback::IvySynchronousApplicationCallback( IvyApplicationCallback *cb ) +{ + target = cb; +} +void IvySynchronousApplicationCallback::OnApplicationConnected( IvyApplication *app) +{ + // duplicate on the Message Queue + IvySynchronousApplicationCallback *param = new IvySynchronousApplicationCallback(target); + param->app = app; + assert(PostMessage(m_synchro->m_hWnd, WM_APPCONNECTED_CB, 0, (LPARAM)param )); +} +void IvySynchronousApplicationCallback::OnApplicationDisconnected( IvyApplication *app) +{ + // duplicate on the Message Queue + IvySynchronousApplicationCallback *param = new IvySynchronousApplicationCallback(target); + param->app = app; + assert(PostMessage(m_synchro->m_hWnd, WM_APPDISCONNECTED_CB, 0, (LPARAM)param )); +} -- cgit v1.1 From 5eb107eaab189823158133d5a0048ed8870d1d17 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:02 +0000 Subject: Utilisateur : Fcolin Date : 30/06/00 Heure : 16:31 Archivé dans $/Ivy (vss 2) --- Ivy/IvySynchroWnd.cxx | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index 297c64e..5e7189c 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -124,6 +124,10 @@ IvySynchronousMessageCallback::IvySynchronousMessageCallback( IvyMessageCallback { target = cb; } +IvySynchronousMessageCallback::~IvySynchronousMessageCallback() +{ + //delete target; +} void IvySynchronousMessageCallback::OnMessage(IvyApplication *app, int argc, const char **argv ) { static int msg_count = 0; -- cgit v1.1 From d22136a194cbe1e54e80feaefbb96c20cadb512a Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:04 +0000 Subject: Utilisateur : Fcolin Date : 21/07/00 Heure : 10:48 Archivé dans $/Ivy Commentaire: separation file cb de la file de message windows (vss 3) --- Ivy/IvySynchroWnd.cxx | 85 +++++++++++++++++++++++++++++---------------------- 1 file changed, 49 insertions(+), 36 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index 5e7189c..80b2622 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -6,9 +6,8 @@ #include "IvySynchroWnd.h" -#define WM_MESSAGE_CB WM_USER + 1001 -#define WM_APPCONNECTED_CB WM_USER + 1002 -#define WM_APPDISCONNECTED_CB WM_USER + 1003 +#define WM_IVY_CB WM_USER + 1001 + IvySynchroWnd* IvySynchronousCallback::m_synchro = NULL; IvySynchroWnd* IvySynchroWnd::m_synchro = NULL; @@ -53,6 +52,7 @@ IvySynchroWnd::IvySynchroWnd() TRACE("Warning: unable to create Ivy Synchro notify window!\n"); //AfxThrowResourceException(); } + InitializeCriticalSection( &m_CritSection ); } IvySynchroWnd::~IvySynchroWnd() @@ -64,16 +64,9 @@ LRESULT CALLBACK IvySynchroWnd::WindowProc( HWND hwnd, UINT uMsg, WPARAM wParam { switch ( uMsg ) { - case WM_MESSAGE_CB: - m_synchro->OnMessageCB( wParam, lParam ); - break; - case WM_APPCONNECTED_CB: - m_synchro->OnApplicationConnectedCB( wParam, lParam ); - break; - case WM_APPDISCONNECTED_CB: - m_synchro->OnApplicationDisconnectedCB( wParam, lParam ); + case WM_IVY_CB: + m_synchro->OnIvyCB( wParam, lParam ); break; - // // Process other messages. // @@ -91,32 +84,28 @@ LRESULT CALLBACK IvySynchroWnd::WindowProc( HWND hwnd, UINT uMsg, WPARAM wParam // IvySynchroWnd message handlers -LRESULT IvySynchroWnd::OnMessageCB(WPARAM wParam, LPARAM lParam) +LRESULT IvySynchroWnd::OnIvyCB(WPARAM wParam, LPARAM lParam) { - IvySynchronousMessageCallback *param = ( IvySynchronousMessageCallback * ) lParam; -// TRACE( "IvySynchroWnd::OnMessageCB msg count %d\n",wParam); - param->target->OnMessage( param->app, param->argc, (const char **) param->argv ); - for( int i = 0; i < param->argc ; i++ ) - free( param->argv[i] ); // allocated with strdup - delete param->argv; // allocated with new + std::list::iterator iter; + EnterCriticalSection( &m_CritSection ); + + for ( iter = callbacklist.begin(); iter != callbacklist.end(); ) + { + IvySynchronousCallback *param = *iter++; + param->CallCallback(); delete param; + } + callbacklist.clear(); + LeaveCriticalSection( &m_CritSection ); return 0L; } -LRESULT IvySynchroWnd::OnApplicationConnectedCB(WPARAM wParam, LPARAM lParam) +void IvySynchroWnd::PostIvyCB( IvySynchronousCallback *cb ) { - IvySynchronousApplicationCallback *param = ( IvySynchronousApplicationCallback * ) lParam; -// TRACE( "IvySynchroWnd::OnSynchroNotify End Synchro\n"); - param->target->OnApplicationConnected( param->app ); - delete param; - return 0L; -} -LRESULT IvySynchroWnd::OnApplicationDisconnectedCB(WPARAM wParam, LPARAM lParam) -{ - IvySynchronousApplicationCallback *param = ( IvySynchronousApplicationCallback * ) lParam; -// TRACE( "IvySynchroWnd::OnSynchroNotify End Synchro\n"); - param->target->OnApplicationDisconnected( param->app ); - delete param; - return 0L; + EnterCriticalSection( &m_CritSection ); + if ( !m_synchro->callbacklist.size() ) + assert(PostMessage(m_synchro->m_hWnd, WM_IVY_CB, 0, 0 )); + m_synchro->callbacklist.push_back( cb ); + LeaveCriticalSection( &m_CritSection ); } // // @@ -139,9 +128,18 @@ void IvySynchronousMessageCallback::OnMessage(IvyApplication *app, int argc, con for( int i = 0; i < argc ; i++ ) param->argv[i] = strdup( argv[i]); // TRACE( "IvySynchronousMessageCallback::OnMessage msg count %d\n",wParam); - assert(PostMessage(m_synchro->m_hWnd, WM_MESSAGE_CB, msg_count++, (LPARAM)param )); + m_synchro->PostIvyCB( param ); } +void IvySynchronousMessageCallback::CallCallback() +{ + target->OnMessage( app, argc, (const char **) argv ); + for( int i = 0; i < argc ; i++ ) + free( argv[i] ); // allocated with strdup + delete argv; // allocated with new +} + + IvySynchronousApplicationCallback::IvySynchronousApplicationCallback( IvyApplicationCallback *cb ) { target = cb; @@ -150,13 +148,28 @@ void IvySynchronousApplicationCallback::OnApplicationConnected( IvyApplication * { // duplicate on the Message Queue IvySynchronousApplicationCallback *param = new IvySynchronousApplicationCallback(target); + param->type = CONNECTED_CB; param->app = app; - assert(PostMessage(m_synchro->m_hWnd, WM_APPCONNECTED_CB, 0, (LPARAM)param )); + m_synchro->PostIvyCB( param ); } + void IvySynchronousApplicationCallback::OnApplicationDisconnected( IvyApplication *app) { // duplicate on the Message Queue IvySynchronousApplicationCallback *param = new IvySynchronousApplicationCallback(target); + param->type = DISCONNECTED_CB; param->app = app; - assert(PostMessage(m_synchro->m_hWnd, WM_APPDISCONNECTED_CB, 0, (LPARAM)param )); + m_synchro->PostIvyCB( param ); } +void IvySynchronousApplicationCallback::CallCallback() +{ + switch ( type ) + { + case CONNECTED_CB: + target->OnApplicationConnected( app ); + break; + case DISCONNECTED_CB: + target->OnApplicationDisconnected( app ); + break; + } +} \ No newline at end of file -- cgit v1.1 From 5aba50d0f42fbe91363d0e06d298ddbccd8df961 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:06 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 4) --- Ivy/IvySynchroWnd.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index 80b2622..12a4587 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -86,7 +86,7 @@ LRESULT CALLBACK IvySynchroWnd::WindowProc( HWND hwnd, UINT uMsg, WPARAM wParam LRESULT IvySynchroWnd::OnIvyCB(WPARAM wParam, LPARAM lParam) { - std::list::iterator iter; + IvySynchronousCallbackList::iterator iter; EnterCriticalSection( &m_CritSection ); for ( iter = callbacklist.begin(); iter != callbacklist.end(); ) @@ -103,7 +103,7 @@ void IvySynchroWnd::PostIvyCB( IvySynchronousCallback *cb ) { EnterCriticalSection( &m_CritSection ); if ( !m_synchro->callbacklist.size() ) - assert(PostMessage(m_synchro->m_hWnd, WM_IVY_CB, 0, 0 )); + ASSERT(PostMessage(m_synchro->m_hWnd, WM_IVY_CB, 0, 0 )); m_synchro->callbacklist.push_back( cb ); LeaveCriticalSection( &m_CritSection ); } -- cgit v1.1 From 897f96895828f2e58459d5a3c7ef57ca652982c5 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:08 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 5) --- Ivy/IvySynchroWnd.cxx | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index 12a4587..2ed6302 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -3,6 +3,12 @@ #include "stdafx.h" +#ifdef _DEBUG +#define DEBUG_NEW new(__FILE__, __LINE__) +#define new DEBUG_NEW +#endif + + #include "IvySynchroWnd.h" @@ -34,7 +40,7 @@ IvySynchroWnd::IvySynchroWnd() wc.hCursor = NULL; // predefined arrow wc.hbrBackground = 0; // white background brush wc.lpszMenuName = NULL; // no menu - wc.lpszClassName = "IvySynchroClass"; // name of window class + wc.lpszClassName = TEXT("IvySynchroClass"); // name of window class // Register the window class. @@ -45,7 +51,7 @@ IvySynchroWnd::IvySynchroWnd() } // Create the syncrho window. - m_hWnd = CreateWindowEx(0, "IvySynchroClass","Ivy Synchro Notification Sink", + m_hWnd = CreateWindowEx(0, TEXT("IvySynchroClass"), TEXT("Ivy Synchro Notification Sink"), WS_OVERLAPPED, 0, 0, 0, 0, NULL , NULL, NULL, NULL); if (!m_hWnd) { @@ -102,7 +108,7 @@ LRESULT IvySynchroWnd::OnIvyCB(WPARAM wParam, LPARAM lParam) void IvySynchroWnd::PostIvyCB( IvySynchronousCallback *cb ) { EnterCriticalSection( &m_CritSection ); - if ( !m_synchro->callbacklist.size() ) + if ( !m_synchro->callbacklist.empty() ) ASSERT(PostMessage(m_synchro->m_hWnd, WM_IVY_CB, 0, 0 )); m_synchro->callbacklist.push_back( cb ); LeaveCriticalSection( &m_CritSection ); @@ -126,7 +132,10 @@ void IvySynchronousMessageCallback::OnMessage(IvyApplication *app, int argc, con param->argc = argc; param->argv = new char*[argc]; for( int i = 0; i < argc ; i++ ) - param->argv[i] = strdup( argv[i]); + { + param->argv[i] = new char[ strlen( argv[i]) +1 ]; + strcpy( param->argv[i], argv[i]); + } // TRACE( "IvySynchronousMessageCallback::OnMessage msg count %d\n",wParam); m_synchro->PostIvyCB( param ); @@ -135,8 +144,8 @@ void IvySynchronousMessageCallback::CallCallback() { target->OnMessage( app, argc, (const char **) argv ); for( int i = 0; i < argc ; i++ ) - free( argv[i] ); // allocated with strdup - delete argv; // allocated with new + delete argv[i]; + delete argv; } -- cgit v1.1 From fbb3f93fb72791aae6c9346d55a42e97b8a605f1 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:10 +0000 Subject: Utilisateur : Fcolin Date : 17/07/01 Heure : 18:25 Archivé dans $/Ivy (vss 6) --- Ivy/IvySynchroWnd.cxx | 5 ----- 1 file changed, 5 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index 2ed6302..33059d8 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -3,11 +3,6 @@ #include "stdafx.h" -#ifdef _DEBUG -#define DEBUG_NEW new(__FILE__, __LINE__) -#define new DEBUG_NEW -#endif - #include "IvySynchroWnd.h" -- cgit v1.1 From d3034a30db643cefc90b690a422b98dd7b2a0713 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:12 +0000 Subject: Utilisateur : Fcolin Date : 9/10/01 Heure : 12:12 Archivé dans $/Ivy Commentaire: on poste un message synchro si la file est vide (vss 7) --- Ivy/IvySynchroWnd.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index 33059d8..e2b2338 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -103,7 +103,7 @@ LRESULT IvySynchroWnd::OnIvyCB(WPARAM wParam, LPARAM lParam) void IvySynchroWnd::PostIvyCB( IvySynchronousCallback *cb ) { EnterCriticalSection( &m_CritSection ); - if ( !m_synchro->callbacklist.empty() ) + if ( m_synchro->callbacklist.empty() ) ASSERT(PostMessage(m_synchro->m_hWnd, WM_IVY_CB, 0, 0 )); m_synchro->callbacklist.push_back( cb ); LeaveCriticalSection( &m_CritSection ); -- cgit v1.1 From 828345b232bd03acc670731a8a1e8b04e93fa528 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:14 +0000 Subject: Utilisateur : Fcolin Date : 5/11/02 Heure : 9:57 Archivé dans $/Bus/Ivy Commentaire: (vss 8) --- Ivy/IvySynchroWnd.cxx | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index e2b2338..cabe92c 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -117,6 +117,11 @@ IvySynchronousMessageCallback::IvySynchronousMessageCallback( IvyMessageCallback IvySynchronousMessageCallback::~IvySynchronousMessageCallback() { //delete target; + for( int i = 0; i < argc ; i++ ) + { + delete argv[i]; + } + if ( argv ) delete argv; } void IvySynchronousMessageCallback::OnMessage(IvyApplication *app, int argc, const char **argv ) { @@ -128,8 +133,7 @@ void IvySynchronousMessageCallback::OnMessage(IvyApplication *app, int argc, con param->argv = new char*[argc]; for( int i = 0; i < argc ; i++ ) { - param->argv[i] = new char[ strlen( argv[i]) +1 ]; - strcpy( param->argv[i], argv[i]); + param->argv[i] = strdup( argv[i]); } // TRACE( "IvySynchronousMessageCallback::OnMessage msg count %d\n",wParam); m_synchro->PostIvyCB( param ); -- cgit v1.1 From 02b8ce0b1e1c0193245917f92f2e1cdb600b3330 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:16 +0000 Subject: Utilisateur : Fcolin Date : 14/11/02 Heure : 15:45 Archivé dans $/Bus/Ivy Commentaire: (vss 9) --- Ivy/IvySynchroWnd.cxx | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index cabe92c..d21a008 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -113,6 +113,9 @@ void IvySynchroWnd::PostIvyCB( IvySynchronousCallback *cb ) IvySynchronousMessageCallback::IvySynchronousMessageCallback( IvyMessageCallback *cb ) { target = cb; + app = 0; + argc = 0; + argv = 0; } IvySynchronousMessageCallback::~IvySynchronousMessageCallback() { -- cgit v1.1 From fea1bcb86df19daf2f08d11ad219ea0dac7be125 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:18 +0000 Subject: Utilisateur : Fcolin Date : 4/02/03 Heure : 8:59 Archivé dans $/Bus/Ivy Commentaire: (vss 10) --- Ivy/IvySynchroWnd.cxx | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index d21a008..67c02d4 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -136,7 +136,11 @@ void IvySynchronousMessageCallback::OnMessage(IvyApplication *app, int argc, con param->argv = new char*[argc]; for( int i = 0; i < argc ; i++ ) { +#ifdef UNDER_CE + param->argv[i] = _strdup( argv[i]); +#else param->argv[i] = strdup( argv[i]); +#endif } // TRACE( "IvySynchronousMessageCallback::OnMessage msg count %d\n",wParam); m_synchro->PostIvyCB( param ); -- cgit v1.1 From bc28a2d4c3bda6f37ad0c056ac7122254a1cb066 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:20 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:45 Archivé dans $/Bus/Ivy Commentaire: (vss 11) --- Ivy/IvySynchroWnd.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index 67c02d4..18c4c43 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -1,7 +1,7 @@ // SynchroWnd.cpp : implementation file // -#include "stdafx.h" +#include "IvyStdAfx.h" #include "IvySynchroWnd.h" -- cgit v1.1 From 71558f893472566b7035f7d7de8df1a9f876374c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:22 +0000 Subject: Utilisateur : Fcolin Date : 16/11/05 Heure : 9:54 Archivé dans $/Bus/Ivy Commentaire: 64 bits ports (vss 12) --- Ivy/IvySynchroWnd.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index 18c4c43..9df473a 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -139,7 +139,7 @@ void IvySynchronousMessageCallback::OnMessage(IvyApplication *app, int argc, con #ifdef UNDER_CE param->argv[i] = _strdup( argv[i]); #else - param->argv[i] = strdup( argv[i]); + param->argv[i] = _strdup( argv[i]); #endif } // TRACE( "IvySynchronousMessageCallback::OnMessage msg count %d\n",wParam); -- cgit v1.1 From 62aca5b9f103f6b8a12e2c1925abb02caa946907 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:24 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 10:14 Archivé dans $/Bus/Ivy Commentaire: ajout Binding Callback et SetFilter (vss 13) --- Ivy/IvySynchroWnd.cxx | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.cxx b/Ivy/IvySynchroWnd.cxx index 9df473a..2109a61 100644 --- a/Ivy/IvySynchroWnd.cxx +++ b/Ivy/IvySynchroWnd.cxx @@ -187,4 +187,57 @@ void IvySynchronousApplicationCallback::CallCallback() target->OnApplicationDisconnected( app ); break; } +} + + +IvySynchronousBindingCallback::IvySynchronousBindingCallback( IvyBindingCallback *cb ) +{ + target = cb; +} +void IvySynchronousBindingCallback::OnAddBind( IvyApplication *app, int id, const char *regexp) +{ + // duplicate on the Message Queue + IvySynchronousBindingCallback *param = new IvySynchronousBindingCallback(target); + param->type = ADD_CB; + param->app = app; + param->id = id; + param->regexp = _strdup(regexp); + m_synchro->PostIvyCB( param ); +} + +void IvySynchronousBindingCallback::OnRemoveBind( IvyApplication *app, int id, const char *regexp) +{ + // duplicate on the Message Queue + IvySynchronousBindingCallback *param = new IvySynchronousBindingCallback(target); + param->type = REMOVE_CB; + param->app = app; + param->id = id; + param->regexp = _strdup(regexp); + m_synchro->PostIvyCB( param ); +} +void IvySynchronousBindingCallback::OnFilterBind( IvyApplication *app, int id, const char *regexp) +{ + // duplicate on the Message Queue + IvySynchronousBindingCallback *param = new IvySynchronousBindingCallback(target); + param->type = FILTER_CB; + param->app = app; + param->id = id; + param->regexp = _strdup(regexp); + m_synchro->PostIvyCB( param ); +} +void IvySynchronousBindingCallback::CallCallback() +{ + switch ( type ) + { + case ADD_CB: + target->OnAddBind( app, id, regexp ); + break; + case REMOVE_CB: + target->OnRemoveBind( app, id, regexp ); + break; + case FILTER_CB: + target->OnFilterBind( app, id, regexp ); + break; + } + delete regexp; } \ No newline at end of file -- cgit v1.1 From cf45b7b1b3cecc0f225e74efbf73c26ed0598956 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:26 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/IvySynchroWnd.h | 97 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 Ivy/IvySynchroWnd.h (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.h b/Ivy/IvySynchroWnd.h new file mode 100644 index 0000000..d497f4a --- /dev/null +++ b/Ivy/IvySynchroWnd.h @@ -0,0 +1,97 @@ +#if !defined(AFX_SYNCHROWND_H__ECAC808C_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_) +#define AFX_SYNCHROWND_H__ECAC808C_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_ + +#if _MSC_VER > 1000 +#pragma once +#endif // _MSC_VER > 1000 +// SynchroWnd.h : header file +// + +///////////////////////////////////////////////////////////////////////////// +// IvySynchroWnd window + +#include "IvyApplication.h" + +class IvySynchroWnd //: public CWnd +{ +// Construction +public: + IvySynchroWnd(); + +// Attributes +public: + +// Operations +public: + void PostMessageCB (IvyMessageCallback *target, IvyApplication *app, int argc, const char **argv ); + void PostApplicationConnectedCB( IvyApplicationCallback *target, IvyApplication *app); + void PostApplicationDisconnectedCB( IvyApplicationCallback *target, IvyApplication *app); + +// Overrides + // ClassWizard generated virtual function overrides + //{{AFX_VIRTUAL(IvySynchroWnd) + //}}AFX_VIRTUAL + +// Implementation +public: + virtual ~IvySynchroWnd(); +protected: + HWND m_hWnd; + +protected: + // Unique instance of this class + static IvySynchroWnd *m_synchro; + // Generated message map functions + static LRESULT CALLBACK WindowProc( + HWND hwnd, // handle to window + UINT uMsg, // message identifier + WPARAM wParam, // first message parameter + LPARAM lParam // second message parameter + ); + +protected: + + LRESULT OnMessageCB(WPARAM wParam, LPARAM lParam); + LRESULT OnApplicationConnectedCB(WPARAM wParam, LPARAM lParam); + LRESULT OnApplicationDisconnectedCB(WPARAM wParam, LPARAM lParam); + friend class IvySynchronousMessageCallback; + friend class IvySynchronousApplicationCallback; + +}; +class IvySynchronousCallback +{ +protected: + IvyApplication *app; + static IvySynchroWnd *m_synchro; + friend class Ivy; +}; +class IvySynchronousMessageCallback: public IvySynchronousCallback, public IvyMessageCallback +{ +public: + IvySynchronousMessageCallback( IvyMessageCallback *cb ); + virtual void OnMessage (IvyApplication *app, int argc, const char **argv ); + +protected: + IvyMessageCallback *target; + int argc; + char **argv; + + friend class IvySynchroWnd; +}; +class IvySynchronousApplicationCallback: public IvySynchronousCallback, public IvyApplicationCallback +{ +public: + IvySynchronousApplicationCallback( IvyApplicationCallback *cb ); + virtual void OnApplicationConnected (IvyApplication *app); + virtual void OnApplicationDisconnected (IvyApplication *app); +protected: + IvyApplicationCallback *target; + + friend class IvySynchroWnd; +}; +///////////////////////////////////////////////////////////////////////////// + +//{{AFX_INSERT_LOCATION}} +// Microsoft Visual C++ will insert additional declarations immediately before the previous line. + +#endif // !defined(AFX_SYNCHROWND_H__ECAC808C_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_) -- cgit v1.1 From dce9bce91bdb923914835b55beb22ae995433eb3 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:28 +0000 Subject: Utilisateur : Fcolin Date : 30/06/00 Heure : 16:31 Archivé dans $/Ivy (vss 2) --- Ivy/IvySynchroWnd.h | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.h b/Ivy/IvySynchroWnd.h index d497f4a..5abd3ff 100644 --- a/Ivy/IvySynchroWnd.h +++ b/Ivy/IvySynchroWnd.h @@ -69,6 +69,7 @@ class IvySynchronousMessageCallback: public IvySynchronousCallback, public IvyM { public: IvySynchronousMessageCallback( IvyMessageCallback *cb ); + virtual ~IvySynchronousMessageCallback(); virtual void OnMessage (IvyApplication *app, int argc, const char **argv ); protected: -- cgit v1.1 From 083e6c611c603c88654be3bc3d60b63212945d3c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:30 +0000 Subject: Utilisateur : Fcolin Date : 21/07/00 Heure : 10:48 Archivé dans $/Ivy Commentaire: separation file cb de la file de message windows (vss 3) --- Ivy/IvySynchroWnd.h | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.h b/Ivy/IvySynchroWnd.h index 5abd3ff..fba864e 100644 --- a/Ivy/IvySynchroWnd.h +++ b/Ivy/IvySynchroWnd.h @@ -12,6 +12,8 @@ #include "IvyApplication.h" +class IvySynchronousCallback; + class IvySynchroWnd //: public CWnd { // Construction @@ -21,12 +23,10 @@ public: // Attributes public: + // Operations public: - void PostMessageCB (IvyMessageCallback *target, IvyApplication *app, int argc, const char **argv ); - void PostApplicationConnectedCB( IvyApplicationCallback *target, IvyApplication *app); - void PostApplicationDisconnectedCB( IvyApplicationCallback *target, IvyApplication *app); - + void PostIvyCB( IvySynchronousCallback *cb ); // Overrides // ClassWizard generated virtual function overrides //{{AFX_VIRTUAL(IvySynchroWnd) @@ -48,12 +48,13 @@ protected: WPARAM wParam, // first message parameter LPARAM lParam // second message parameter ); + // Buffer Emission + CRITICAL_SECTION m_CritSection; + std::list callbacklist; protected: - LRESULT OnMessageCB(WPARAM wParam, LPARAM lParam); - LRESULT OnApplicationConnectedCB(WPARAM wParam, LPARAM lParam); - LRESULT OnApplicationDisconnectedCB(WPARAM wParam, LPARAM lParam); + LRESULT OnIvyCB(WPARAM wParam, LPARAM lParam); friend class IvySynchronousMessageCallback; friend class IvySynchronousApplicationCallback; @@ -64,12 +65,16 @@ protected: IvyApplication *app; static IvySynchroWnd *m_synchro; friend class Ivy; +public: + virtual void CallCallback() = 0; + }; class IvySynchronousMessageCallback: public IvySynchronousCallback, public IvyMessageCallback { public: IvySynchronousMessageCallback( IvyMessageCallback *cb ); virtual ~IvySynchronousMessageCallback(); + virtual void CallCallback(); virtual void OnMessage (IvyApplication *app, int argc, const char **argv ); protected: @@ -83,11 +88,14 @@ class IvySynchronousApplicationCallback: public IvySynchronousCallback, public { public: IvySynchronousApplicationCallback( IvyApplicationCallback *cb ); + virtual void CallCallback(); virtual void OnApplicationConnected (IvyApplication *app); virtual void OnApplicationDisconnected (IvyApplication *app); protected: IvyApplicationCallback *target; - + typedef enum { CONNECTED_CB, DISCONNECTED_CB } CallbackType; + CallbackType type; + friend class IvySynchroWnd; }; ///////////////////////////////////////////////////////////////////////////// -- cgit v1.1 From 01f17249cc38ce6e98b1982d5b111144cf8e1aa6 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:32 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 4) --- Ivy/IvySynchroWnd.h | 24 +++++------------------- 1 file changed, 5 insertions(+), 19 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.h b/Ivy/IvySynchroWnd.h index fba864e..ceb7aa3 100644 --- a/Ivy/IvySynchroWnd.h +++ b/Ivy/IvySynchroWnd.h @@ -1,12 +1,7 @@ -#if !defined(AFX_SYNCHROWND_H__ECAC808C_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_) -#define AFX_SYNCHROWND_H__ECAC808C_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_ - -#if _MSC_VER > 1000 -#pragma once -#endif // _MSC_VER > 1000 +// // SynchroWnd.h : header file // - +#pragma once ///////////////////////////////////////////////////////////////////////////// // IvySynchroWnd window @@ -14,7 +9,7 @@ class IvySynchronousCallback; -class IvySynchroWnd //: public CWnd +class IvySynchroWnd { // Construction public: @@ -27,10 +22,6 @@ public: // Operations public: void PostIvyCB( IvySynchronousCallback *cb ); -// Overrides - // ClassWizard generated virtual function overrides - //{{AFX_VIRTUAL(IvySynchroWnd) - //}}AFX_VIRTUAL // Implementation public: @@ -50,7 +41,8 @@ protected: ); // Buffer Emission CRITICAL_SECTION m_CritSection; - std::list callbacklist; + typedef list IvySynchronousCallbackList; + IvySynchronousCallbackList callbacklist; protected: @@ -98,9 +90,3 @@ protected: friend class IvySynchroWnd; }; -///////////////////////////////////////////////////////////////////////////// - -//{{AFX_INSERT_LOCATION}} -// Microsoft Visual C++ will insert additional declarations immediately before the previous line. - -#endif // !defined(AFX_SYNCHROWND_H__ECAC808C_3B4D_11D3_8A1E_00A0245B298A__INCLUDED_) -- cgit v1.1 From ca7d7e10e8d548eabab6ae7dd7f15b885f338e05 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:34 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 5) --- Ivy/IvySynchroWnd.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.h b/Ivy/IvySynchroWnd.h index ceb7aa3..b21b2b3 100644 --- a/Ivy/IvySynchroWnd.h +++ b/Ivy/IvySynchroWnd.h @@ -41,7 +41,7 @@ protected: ); // Buffer Emission CRITICAL_SECTION m_CritSection; - typedef list IvySynchronousCallbackList; + typedef ivy::list IvySynchronousCallbackList; IvySynchronousCallbackList callbacklist; protected: -- cgit v1.1 From 33d722d0f56256e7e0aff49063c95c4d0fe44877 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:36 +0000 Subject: Utilisateur : Fcolin Date : 1/06/06 Heure : 10:14 Archivé dans $/Bus/Ivy Commentaire: ajout Binding Callback et SetFilter (vss 6) --- Ivy/IvySynchroWnd.h | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvySynchroWnd.h b/Ivy/IvySynchroWnd.h index b21b2b3..ffa44ba 100644 --- a/Ivy/IvySynchroWnd.h +++ b/Ivy/IvySynchroWnd.h @@ -90,3 +90,20 @@ protected: friend class IvySynchroWnd; }; +class IvySynchronousBindingCallback: public IvySynchronousCallback, public IvyBindingCallback +{ +public: + IvySynchronousBindingCallback( IvyBindingCallback *cb ); + virtual void CallCallback(); + virtual void OnAddBind (IvyApplication *app, int id, const char *regexp); + virtual void OnRemoveBind (IvyApplication *app, int id, const char *regexp); + virtual void OnFilterBind (IvyApplication *app, int id, const char *regexp); +protected: + IvyBindingCallback *target; + typedef enum { ADD_CB, REMOVE_CB, FILTER_CB } CallbackType; + CallbackType type; + int id; + const char *regexp; + + friend class IvySynchroWnd; +}; -- cgit v1.1 From 614da7f1a522dc1f234269d3f6422542758ac928 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:38 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/IvyWatcher.cxx | 114 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 Ivy/IvyWatcher.cxx (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx new file mode 100644 index 0000000..c963968 --- /dev/null +++ b/Ivy/IvyWatcher.cxx @@ -0,0 +1,114 @@ +// IvyWatcher.cpp : implementation file +// + +#include "stdafx.h" + +#include "IvyWatcher.h" +#include "IvyApplication.h" + +///////////////////////////////////////////////////////////////////////////// +// IvyWatcher + + +#define VERSION 3 + +IvyWatcher::IvyWatcher(Ivy * bus) +{ + this->bus = bus; +} +IvyWatcher::~IvyWatcher() +{ +} + + + +///////////////////////////////////////////////////////////////////////////// +// IvyWatcher member functions + +void IvyWatcher::OnReceive(int nErrorCode) +{ + int err; + int version; + char buffer[256]; + string remotehost; + UINT remoteport; + UINT serviceport; + + + err = ReceiveFrom( buffer, sizeof(buffer), remotehost, remoteport ); + if ( err == SOCKET_ERROR ) + { + TRACE("Receive Broadcast error %d\n",GetLastError()); + return; + } + buffer[err] ='\0'; + err = sscanf(buffer,"%d %u",&version, &serviceport); + if ( err != 2 ) + { + /* ignore the message */ + TRACE(" Bad Supervision message expected 'version port'\n"); + return; + } + if ( version != VERSION ) + { + /* ignore the message */ + TRACE(" Bad Ivy verion number expected %d receive %d from %s:%d\n", VERSION,version, remotehost, remoteport); + return; + } + /* check if we receive our own message should test also the host */ + if ( serviceport == bus->GetApplicationPort() /*&& remotehost == "localhost"*/) return; + TRACE(" Broadcast de %s:%u port %u\n", remotehost.c_str(), remoteport, serviceport ); + + /* connect to the service and send the regexp */ + IvyApplication *newapp = new IvyApplication(bus); + // exception to catch + newapp->Create(remotehost.c_str(), serviceport); + // delete newapp; + // return; + + bus->AddApplication( newapp ); + TRACE(" Connecting to %s:%u\n", remotehost.c_str(), serviceport ); + +} + +void IvyWatcher::start(const char *domainlist) +{ + BOOL reuse = TRUE; + string domain; + UINT port; + // determine domain to use + domain = bus->GetDomain( domainlist ); + + // first find our UDP port + int sep_index = domain.rfind( ':' ); + if ( sep_index != -1 ) + { + port = atoi ( domain.substr( sep_index +1 ).c_str() ); + // supress port number from end of domain list + domain.erase( sep_index, domain.length() - sep_index ); + } + // create UDP receiver + // catch exception !!! + Socket(SOCK_DGRAM); + SetSockOpt( SO_REUSEADDR, &reuse, sizeof(BOOL) ); + Bind(port); + + string addr; + char hello[1024]; + int len = sprintf( hello, "%d %u\n", VERSION, bus->GetApplicationPort() ); + + // send broadcast to domain list + while ( !domain.empty() ) + { + // find addr up to separator + int index = domain.find_first_of( ", \t" ); + addr = domain.substr( 0, index ); + domain.erase( 0, addr.length() +1 ); + TRACE("Ivy Broadcasting on %s:%d\n", addr.c_str(), port ); + SendTo( hello, len, port, addr.c_str() ); + } +} +void IvyWatcher::stop() +{ + Close(); +} -- cgit v1.1 From 95b2373c6e00b8a57e88008c934634bd8e2e17bd Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:40 +0000 Subject: Utilisateur : Fcolin Date : 29/06/00 Heure : 15:59 Archivé dans $/Ivy Commentaire: Version multicast (vss 2) --- Ivy/IvyWatcher.cxx | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index c963968..099e670 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -105,6 +105,7 @@ void IvyWatcher::start(const char *domainlist) addr = domain.substr( 0, index ); domain.erase( 0, addr.length() +1 ); TRACE("Ivy Broadcasting on %s:%d\n", addr.c_str(), port ); + AddMember( addr.c_str() ); SendTo( hello, len, port, addr.c_str() ); } } -- cgit v1.1 From 0c05305dc38012e87d470b972cf88aef26f71425 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:42 +0000 Subject: Utilisateur : Fcolin Date : 23/01/01 Heure : 13:12 Archivé dans $/Ivy Commentaire: remove 'using name space std;' (vss 3) --- Ivy/IvyWatcher.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index 099e670..a363bdc 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -30,7 +30,7 @@ void IvyWatcher::OnReceive(int nErrorCode) int err; int version; char buffer[256]; - string remotehost; + String remotehost; UINT remoteport; UINT serviceport; @@ -74,7 +74,7 @@ void IvyWatcher::OnReceive(int nErrorCode) void IvyWatcher::start(const char *domainlist) { BOOL reuse = TRUE; - string domain; + String domain; UINT port; // determine domain to use domain = bus->GetDomain( domainlist ); @@ -93,7 +93,7 @@ void IvyWatcher::start(const char *domainlist) SetSockOpt( SO_REUSEADDR, &reuse, sizeof(BOOL) ); Bind(port); - string addr; + String addr; char hello[1024]; int len = sprintf( hello, "%d %u\n", VERSION, bus->GetApplicationPort() ); -- cgit v1.1 From a30fc57b42e9b6846aab57d41f34291da563bdaa Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:44 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 4) --- Ivy/IvyWatcher.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index a363bdc..099e670 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -30,7 +30,7 @@ void IvyWatcher::OnReceive(int nErrorCode) int err; int version; char buffer[256]; - String remotehost; + string remotehost; UINT remoteport; UINT serviceport; @@ -74,7 +74,7 @@ void IvyWatcher::OnReceive(int nErrorCode) void IvyWatcher::start(const char *domainlist) { BOOL reuse = TRUE; - String domain; + string domain; UINT port; // determine domain to use domain = bus->GetDomain( domainlist ); @@ -93,7 +93,7 @@ void IvyWatcher::start(const char *domainlist) SetSockOpt( SO_REUSEADDR, &reuse, sizeof(BOOL) ); Bind(port); - String addr; + string addr; char hello[1024]; int len = sprintf( hello, "%d %u\n", VERSION, bus->GetApplicationPort() ); -- cgit v1.1 From db65e6f46e6394f813148f179a08573752f5c220 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:46 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 5) --- Ivy/IvyWatcher.cxx | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index 099e670..8bd46bf 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -3,6 +3,11 @@ #include "stdafx.h" +#ifdef _DEBUG +#define DEBUG_NEW new(__FILE__, __LINE__) +#define new DEBUG_NEW +#endif + #include "IvyWatcher.h" #include "IvyApplication.h" -- cgit v1.1 From 0944a08b5666a732ce74d888b34d8b3f3cca4535 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:48 +0000 Subject: Utilisateur : Fcolin Date : 23/05/01 Heure : 10:25 Archivé dans $/Ivy (vss 6) --- Ivy/IvyWatcher.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index 8bd46bf..57f054c 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -43,7 +43,7 @@ void IvyWatcher::OnReceive(int nErrorCode) err = ReceiveFrom( buffer, sizeof(buffer), remotehost, remoteport ); if ( err == SOCKET_ERROR ) { - TRACE("Receive Broadcast error %d\n",GetLastError()); + TRACE("Receive Broadcast error %d\n",this->GetLastError()); return; } buffer[err] ='\0'; -- cgit v1.1 From d0988d727ee447c4a268644b36c93ba572205f82 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:50 +0000 Subject: Utilisateur : Fcolin Date : 17/07/01 Heure : 18:25 Archivé dans $/Ivy (vss 7) --- Ivy/IvyWatcher.cxx | 4 ---- 1 file changed, 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index 57f054c..4101d11 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -3,10 +3,6 @@ #include "stdafx.h" -#ifdef _DEBUG -#define DEBUG_NEW new(__FILE__, __LINE__) -#define new DEBUG_NEW -#endif #include "IvyWatcher.h" #include "IvyApplication.h" -- cgit v1.1 From 013d410ea25c166272b79a452155be6190c4862c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:52 +0000 Subject: Utilisateur : Fcolin Date : 17/09/01 Heure : 15:46 Archivé dans $/Ivy Commentaire: manque start listener pour UDP socket (vss 8) --- Ivy/IvyWatcher.cxx | 1 + 1 file changed, 1 insertion(+) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index 4101d11..d20bfa3 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -93,6 +93,7 @@ void IvyWatcher::start(const char *domainlist) Socket(SOCK_DGRAM); SetSockOpt( SO_REUSEADDR, &reuse, sizeof(BOOL) ); Bind(port); + StartListener(); string addr; char hello[1024]; -- cgit v1.1 From 84c5a1c5084da8841b3de03cd07db6ceb7cbbdf8 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:54 +0000 Subject: Utilisateur : Fcolin Date : 19/06/02 Heure : 15:14 Archivé dans $/Ivy (vss 9) --- Ivy/IvyWatcher.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index d20bfa3..8df0ac4 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -76,7 +76,7 @@ void IvyWatcher::start(const char *domainlist) { BOOL reuse = TRUE; string domain; - UINT port; + UINT port=0; // determine domain to use domain = bus->GetDomain( domainlist ); -- cgit v1.1 From efde241a613f12c035898c99eb7595a97f8fe06d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:56 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:45 Archivé dans $/Bus/Ivy Commentaire: (vss 10) --- Ivy/IvyWatcher.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index 8df0ac4..af19fe5 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -1,7 +1,7 @@ // IvyWatcher.cpp : implementation file // -#include "stdafx.h" +#include "IvyStdAfx.h" #include "IvyWatcher.h" @@ -97,7 +97,7 @@ void IvyWatcher::start(const char *domainlist) string addr; char hello[1024]; - int len = sprintf( hello, "%d %u\n", VERSION, bus->GetApplicationPort() ); + int len = _snprintf( hello, sizeof(hello), "%d %u\n", VERSION, bus->GetApplicationPort() ); // send broadcast to domain list while ( !domain.empty() ) -- cgit v1.1 From c7b04986097c2c4fa6e0d9ad00bdaf5dff9cdeec Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:03:58 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 11) --- Ivy/IvyWatcher.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index af19fe5..424c8ac 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -31,7 +31,7 @@ void IvyWatcher::OnReceive(int nErrorCode) int err; int version; char buffer[256]; - string remotehost; + ivy::string remotehost; UINT remoteport; UINT serviceport; @@ -53,7 +53,7 @@ void IvyWatcher::OnReceive(int nErrorCode) if ( version != VERSION ) { /* ignore the message */ - TRACE(" Bad Ivy verion number expected %d receive %d from %s:%d\n", VERSION,version, remotehost, remoteport); + TRACE(" Bad Ivy verion number expected %d receive %d from %s:%d\n", VERSION,version, remotehost.c_str(), remoteport); return; } /* check if we receive our own message should test also the host */ @@ -75,7 +75,7 @@ void IvyWatcher::OnReceive(int nErrorCode) void IvyWatcher::start(const char *domainlist) { BOOL reuse = TRUE; - string domain; + ivy::string domain; UINT port=0; // determine domain to use domain = bus->GetDomain( domainlist ); @@ -95,7 +95,7 @@ void IvyWatcher::start(const char *domainlist) Bind(port); StartListener(); - string addr; + ivy::string addr; char hello[1024]; int len = _snprintf( hello, sizeof(hello), "%d %u\n", VERSION, bus->GetApplicationPort() ); -- cgit v1.1 From f67017bf198b8d5cce6cbe7823a20e052e12b3d6 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:00 +0000 Subject: Utilisateur : Fcolin Date : 23/09/05 Heure : 15:27 Archivé dans $/Bus/Ivy Commentaire: (vss 12) --- Ivy/IvyWatcher.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index 424c8ac..4faca90 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -28,7 +28,7 @@ IvyWatcher::~IvyWatcher() void IvyWatcher::OnReceive(int nErrorCode) { - int err; + size_t err; int version; char buffer[256]; ivy::string remotehost; @@ -81,7 +81,7 @@ void IvyWatcher::start(const char *domainlist) domain = bus->GetDomain( domainlist ); // first find our UDP port - int sep_index = domain.rfind( ':' ); + size_t sep_index = domain.rfind( ':' ); if ( sep_index != -1 ) { port = atoi ( domain.substr( sep_index +1 ).c_str() ); @@ -103,7 +103,7 @@ void IvyWatcher::start(const char *domainlist) while ( !domain.empty() ) { // find addr up to separator - int index = domain.find_first_of( ", \t" ); + size_t index = domain.find_first_of( ", \t" ); addr = domain.substr( 0, index ); domain.erase( 0, addr.length() +1 ); TRACE("Ivy Broadcasting on %s:%d\n", addr.c_str(), port ); -- cgit v1.1 From f7cffc1477ac2dffa98bca7f9cd5b589ef62f00d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:02 +0000 Subject: Utilisateur : Fcolin Date : 16/11/05 Heure : 9:54 Archivé dans $/Bus/Ivy Commentaire: 64 bits ports (vss 13) --- Ivy/IvyWatcher.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index 4faca90..d9f8cf8 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -43,7 +43,7 @@ void IvyWatcher::OnReceive(int nErrorCode) return; } buffer[err] ='\0'; - err = sscanf(buffer,"%d %u",&version, &serviceport); + err = sscanf_s(buffer,"%d %u",&version, &serviceport); if ( err != 2 ) { /* ignore the message */ @@ -97,7 +97,7 @@ void IvyWatcher::start(const char *domainlist) ivy::string addr; char hello[1024]; - int len = _snprintf( hello, sizeof(hello), "%d %u\n", VERSION, bus->GetApplicationPort() ); + int len = _snprintf_s( hello, sizeof(hello), sizeof(hello)-1, "%d %u\n", VERSION, bus->GetApplicationPort() ); // send broadcast to domain list while ( !domain.empty() ) -- cgit v1.1 From 2ee1ed697edc42aae7962877a5649e2c280741b8 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:04 +0000 Subject: Utilisateur : Fcolin Date : 19/04/06 Heure : 15:07 Archivé dans $/Bus/Ivy Commentaire: (vss 14) --- Ivy/IvyWatcher.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index d9f8cf8..e2a2783 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -42,7 +42,7 @@ void IvyWatcher::OnReceive(int nErrorCode) TRACE("Receive Broadcast error %d\n",this->GetLastError()); return; } - buffer[err] ='\0'; + if ( err < 255 ) buffer[err] ='\0'; err = sscanf_s(buffer,"%d %u",&version, &serviceport); if ( err != 2 ) { -- cgit v1.1 From a590fa8d95a798b1a4f750ed9b5b85e9e642e701 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:06 +0000 Subject: Utilisateur : Fcolin Date : 23/05/06 Heure : 18:18 Archivé dans $/Bus/Ivy Commentaire: Modification protocol UDP (vss 15) --- Ivy/IvyWatcher.cxx | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.cxx b/Ivy/IvyWatcher.cxx index e2a2783..4cbf604 100644 --- a/Ivy/IvyWatcher.cxx +++ b/Ivy/IvyWatcher.cxx @@ -30,12 +30,16 @@ void IvyWatcher::OnReceive(int nErrorCode) { size_t err; int version; - char buffer[256]; + char buffer[2048]; ivy::string remotehost; UINT remoteport; UINT serviceport; + char appid[2048]; + char appname[2048]; - + memset( appid, 0, sizeof( appid ) ); + memset( appname, 0, sizeof( appname ) ); + err = ReceiveFrom( buffer, sizeof(buffer), remotehost, remoteport ); if ( err == SOCKET_ERROR ) { @@ -43,8 +47,8 @@ void IvyWatcher::OnReceive(int nErrorCode) return; } if ( err < 255 ) buffer[err] ='\0'; - err = sscanf_s(buffer,"%d %u",&version, &serviceport); - if ( err != 2 ) + err = sscanf_s(buffer,"%d %u %s %[^\n]",&version, &serviceport,appid, sizeof(appid), appname,sizeof(appname)); + if ( err < 2 ) { /* ignore the message */ TRACE(" Bad Supervision message expected 'version port'\n"); @@ -56,6 +60,9 @@ void IvyWatcher::OnReceive(int nErrorCode) TRACE(" Bad Ivy verion number expected %d receive %d from %s:%d\n", VERSION,version, remotehost.c_str(), remoteport); return; } + /* check if we received our own message. SHOULD ALSO TEST THE HOST */ + if ( strcmp( appid , bus->ApplicationID.c_str()) ==0 ) return; + /* check if we receive our own message should test also the host */ if ( serviceport == bus->GetApplicationPort() /*&& remotehost == "localhost"*/) return; TRACE(" Broadcast de %s:%u port %u\n", remotehost.c_str(), remoteport, serviceport ); @@ -63,7 +70,7 @@ void IvyWatcher::OnReceive(int nErrorCode) /* connect to the service and send the regexp */ IvyApplication *newapp = new IvyApplication(bus); // exception to catch - newapp->Create(remotehost.c_str(), serviceport); + newapp->Create(remotehost.c_str(), serviceport, appname ); // delete newapp; // return; @@ -96,8 +103,8 @@ void IvyWatcher::start(const char *domainlist) StartListener(); ivy::string addr; - char hello[1024]; - int len = _snprintf_s( hello, sizeof(hello), sizeof(hello)-1, "%d %u\n", VERSION, bus->GetApplicationPort() ); + char hello[2048]; + int len = _snprintf_s( hello, sizeof(hello), sizeof(hello)-1, "%d %u %s %s\n", VERSION, bus->GetApplicationPort(), bus->ApplicationID.c_str(), bus->ApplicationName.c_str() ); // send broadcast to domain list while ( !domain.empty() ) -- cgit v1.1 From dc3740113a3db349f005ee5e4a948cb5d9972120 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:08 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/IvyWatcher.h | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 Ivy/IvyWatcher.h (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.h b/Ivy/IvyWatcher.h new file mode 100644 index 0000000..7836a90 --- /dev/null +++ b/Ivy/IvyWatcher.h @@ -0,0 +1,52 @@ +#if !defined(AFX_BUSWATCHER_H__F7F08FE7_E653_11D0_AE3E_080009F92591__INCLUDED_) +#define AFX_BUSWATCHER_H__F7F08FE7_E653_11D0_AE3E_080009F92591__INCLUDED_ + +#if _MSC_VER >= 1000 +#pragma once +#endif // _MSC_VER >= 1000 +// IvyWatcher.h : header file +// + +#include "stdafx.h" +#include "ThreadedSocket.h" +#include "Ivy.h" + +///////////////////////////////////////////////////////////////////////////// +// IvyWatcher command target + +class IvyWatcher : public CThreadedSocket +{ +// Attributes +public: + +// Operations +public: + IvyWatcher(Ivy *bus); + virtual ~IvyWatcher(); +// Overrides +public: + void start(const char *domain); + void stop(); + // ClassWizard generated virtual function overrides + //{{AFX_VIRTUAL(IvyWatcher) + public: + virtual void OnReceive(int nErrorCode); + //}}AFX_VIRTUAL + + // Generated message map functions + //{{AFX_MSG(IvyWatcher) + // NOTE - the ClassWizard will add and remove member functions here. + //}}AFX_MSG + +// Implementation +protected: + Ivy * bus; + +}; + +///////////////////////////////////////////////////////////////////////////// + +//{{AFX_INSERT_LOCATION}} +// Microsoft Developer Studio will insert additional declarations immediately before the previous line. + +#endif // !defined(AFX_BUSWATCHER_H__F7F08FE7_E653_11D0_AE3E_080009F92591__INCLUDED_) -- cgit v1.1 From 33911345aa6a44706e2d805f91fa2ffd4fd717cb Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:10 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 2) --- Ivy/IvyWatcher.h | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.h b/Ivy/IvyWatcher.h index 7836a90..4ba4140 100644 --- a/Ivy/IvyWatcher.h +++ b/Ivy/IvyWatcher.h @@ -1,9 +1,6 @@ -#if !defined(AFX_BUSWATCHER_H__F7F08FE7_E653_11D0_AE3E_080009F92591__INCLUDED_) -#define AFX_BUSWATCHER_H__F7F08FE7_E653_11D0_AE3E_080009F92591__INCLUDED_ -#if _MSC_VER >= 1000 #pragma once -#endif // _MSC_VER >= 1000 + // IvyWatcher.h : header file // @@ -27,16 +24,7 @@ public: public: void start(const char *domain); void stop(); - // ClassWizard generated virtual function overrides - //{{AFX_VIRTUAL(IvyWatcher) - public: virtual void OnReceive(int nErrorCode); - //}}AFX_VIRTUAL - - // Generated message map functions - //{{AFX_MSG(IvyWatcher) - // NOTE - the ClassWizard will add and remove member functions here. - //}}AFX_MSG // Implementation protected: @@ -44,9 +32,3 @@ protected: }; -///////////////////////////////////////////////////////////////////////////// - -//{{AFX_INSERT_LOCATION}} -// Microsoft Developer Studio will insert additional declarations immediately before the previous line. - -#endif // !defined(AFX_BUSWATCHER_H__F7F08FE7_E653_11D0_AE3E_080009F92591__INCLUDED_) -- cgit v1.1 From 6cf1d6c20897df937876e85d3d589ab63fb7cdf8 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:12 +0000 Subject: Utilisateur : Fcolin Date : 20/02/01 Heure : 10:27 Archivé dans $/Ivy (vss 3) --- Ivy/IvyWatcher.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/IvyWatcher.h b/Ivy/IvyWatcher.h index 4ba4140..1eb0718 100644 --- a/Ivy/IvyWatcher.h +++ b/Ivy/IvyWatcher.h @@ -4,7 +4,7 @@ // IvyWatcher.h : header file // -#include "stdafx.h" + #include "ThreadedSocket.h" #include "Ivy.h" -- cgit v1.1 From 7bcca6c9c8668abc5bf03fdc23a19676dc25b222 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:14 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/Regexp.cxx | 1757 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1757 insertions(+) create mode 100644 Ivy/Regexp.cxx (limited to 'Ivy') diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx new file mode 100644 index 0000000..6d44def --- /dev/null +++ b/Ivy/Regexp.cxx @@ -0,0 +1,1757 @@ +// Win32 porting notes. + +#if defined( _MBCS ) +#pragma message( __FILEINFO__ "This code is broken under _MBCS, " \ + "see the comments at the top of this file." ) +#endif //_MBCS +// +// +// In case this isn't obvious from the later comments this is an ALTERED +// version of the software. If you like my changes then cool, but nearly +// all of the functionality here is derived from Henry Spencer's original +// work. +// +// This code should work correctly under both _SBCS and _UNICODE, I did +// start working on making it work with _MBCS but gave up after a while +// since I don't need this particular port and it's not going to be as +// straight forward as the other two. +// +// The problem stems from the compiled program being stored as TCHARS, +// the individual items need to be wide enough to hold whatever character +// is thrown at them, but currently they are accessed as an array of +// whatever size integral type is appropriate. _MBCS would cause this +// to be char, but at times it would need to be larger. This would +// require making the program be an array of short with the appropriate +// conversions used everywhere. Certainly it's doable, but it's a pain. +// What's worse is that the current code will compile and run under _MBCS, +// only breaking when it gets wide characters thrown against it. +// +// I've marked at least one bit of code with #pragma messages, I may not +// get all of them, but they should be a start +// +// Guy Gascoigne - Piggford (ggp@bigfoot.com) Friday, February 27, 1998 + + +// regcomp and regexec -- regsub and regerror are elsewhere +// @(#)regexp.c 1.3 of 18 April 87 +// +// Copyright (c) 1986 by University of Toronto. +// Written by Henry Spencer. Not derived from licensed software. +// +// Permission is granted to anyone to use this software for any +// purpose on any computer system, and to redistribute it freely, +// subject to the following restrictions: +// +// 1. The author is not responsible for the consequences of use of +// this software, no matter how awful, even if they arise +// from defects in it. +// +// 2. The origin of this software must not be misrepresented, either +// by explicit claim or by omission. +// +// 3. Altered versions must be plainly marked as such, and must not +// be misrepresented as being the original software. +// *** THIS IS AN ALTERED VERSION. It was altered by John Gilmore, +// *** hoptoad!gnu, on 27 Dec 1986, to add \< and \> for word-matching +// *** as in BSD grep and ex. +// *** THIS IS AN ALTERED VERSION. It was altered by John Gilmore, +// *** hoptoad!gnu, on 28 Dec 1986, to optimize characters quoted with \. +// *** THIS IS AN ALTERED VERSION. It was altered by James A. Woods, +// *** ames!jaw, on 19 June 1987, to quash a regcomp() redundancy. +// *** THIS IS AN ALTERED VERSION. It was altered by Geoffrey Noer, +// *** THIS IS AN ALTERED VERSION. It was altered by Guy Gascoigne - Piggford +// *** guy@wyrdrune.com, on 15 March 1998, porting it to C++ and converting +// *** it to be the engine for the Regexp class +// +// Beware that some of this code is subtly aware of the way operator +// precedence is structured in regular expressions. Serious changes in +// regular-expression syntax might require a total rethink. + +#include "stdafx.h" +#include "regexp.h" + +// The first byte of the regexp internal "program" is actually this magic +// number; the start node begins in the second byte. + +const char MAGIC = '\234'; + +#pragma warning( disable : 4711 ) // automatic inline selected + +// The "internal use only" fields in regexp.h are present to pass info from +// compile to execute that permits the execute phase to run lots faster on +// simple cases. They are: +// +// regstart char that must begin a match; '\0' if none obvious +// reganch is the match anchored (at beginning-of-line only)? +// regmust string (pointer into program) that match must include, or NULL +// regmlen length of regmust string +// +// Regstart and reganch permit very fast decisions on suitable starting +// points for a match, cutting down the work a lot. Regmust permits fast +// rejection of lines that cannot possibly match. The regmust tests are +// costly enough that regcomp() supplies a regmust only if the +// r.e. contains something potentially expensive (at present, the only +// such thing detected is * or + at the start of the r.e., which can +// involve a lot of backup). Regmlen is supplied because the test in +// regexec() needs it and regcomp() is computing it anyway. + +// Structure for regexp "program". This is essentially a linear encoding +// of a nondeterministic finite-state machine (aka syntax charts or +// "railroad normal form" in parsing technology). Each node is an opcode +// plus a "next" pointer, possibly plus an operand. "Next" pointers of +// all nodes except BRANCH implement concatenation; a "next" pointer with +// a BRANCH on both ends of it is connecting two alternatives. (Here we +// have one of the subtle syntax dependencies: an individual BRANCH (as +// opposed to a collection of them) is never concatenated with anything +// because of operator precedence.) The operand of some types of node is +// a literal string; for others, it is a node leading into a sub-FSM. In +// particular, the operand of a BRANCH node is the first node of the +// branch. (NB this is *not* a tree structure: the tail of the branch +// connects to the thing following the set of BRANCHes.) The opcodes +// are: + +enum { +// definition number opnd? meaning + END = 0, // no End of program. + BOL = 1, // no Match beginning of line. + EOL = 2, // no Match end of line. + ANY = 3, // no Match any character. + ANYOF = 4, // str Match any of these. + ANYBUT = 5, // str Match any but one of these. + BRANCH = 6, // node Match this, or the next..\&. + BACK = 7, // no "next" ptr points backward. + EXACTLY = 8, // str Match this string. + NOTHING = 9, // no Match empty string. + STAR = 10, // node Match this 0 or more times. + PLUS = 11, // node Match this 1 or more times. + WORDA = 12, // no Match "" at wordchar, where prev is nonword + WORDZ = 13, // no Match "" at nonwordchar, where prev is word + OPEN = 20, // no Sub-RE starts here. + // OPEN+1 is number 1, etc. + CLOSE = 40 // no Analogous to OPEN. +}; + +// Opcode notes: +// +// BRANCH The set of branches constituting a single choice are hooked +// together with their "next" pointers, since precedence prevents +// anything being concatenated to any individual branch. The +// "next" pointer of the last BRANCH in a choice points to the +// thing following the whole choice. This is also where the +// final "next" pointer of each individual branch points; each +// branch starts with the operand node of a BRANCH node. +// +// BACK Normal "next" pointers all implicitly point forward; BACK +// exists to make loop structures possible. +// +// STAR,PLUS '?', and complex '*' and '+', are implemented as circular +// BRANCH structures using BACK. Simple cases (one character +// per match) are implemented with STAR and PLUS for speed +// and to minimize recursive plunges. +// +// OPEN,CLOSE ...are numbered at compile time. + +// A node is one char of opcode followed by two chars of "next" pointer. +// "Next" pointers are stored as two 8-bit pieces, high order first. The +// value is a positive offset from the opcode of the node containing it. +// An operand, if any, simply follows the node. (Note that much of the +// code generation knows about this implicit relationship.) +// +// Using two bytes for the "next" pointer is vast overkill for most things, +// but allows patterns to get big without disasters. + + +enum +{ + REGERR_SENTINEL_VALUE = 0, + REGERR_NULLARG = 1, REGERR_CORRUPTED, REGERR_CORRUPTION, REGERR_CORRUPTED_POINTERS, + REGERR_BAD_REGREPEAT, REGERR_CORRUPTED_OPCODE, REGERR_NULL_TO_REGSUB, + REGERR_DAMAGED_REGEXP_REGSUB, REGERR_DAMAGED_MATCH_STRING, REGERR_NULL_TO_REGCOMP, + REGERR_TO_BIG, REGERR_TO_MANY_PAREN, REGERR_UNTERMINATED_PAREN, REGERR_UNMATCHED_PAREN, + REGERR_INTERNAL_ERROR_JUNK, REGERR_OP_COULD_BE_EMPTY, REGERR_NESTED_OP, REGERR_INVALID_RANGE, + REGERR_UNMATCHED_BRACE, REGERR_INTERNAL_UNEXPECTED_CHAR, REGERR_OP_FOLLOWS_NOTHING, + REGERR_TRAILING_ESC, REGERR_INTERNAL_STRSCSPN, REGERR_NO_REGEXP +}; + +struct regErr +{ + int m_id; + const char * m_err; +} errors[] = { + { REGERR_NULLARG, "NULL argument to regexec" }, + { REGERR_CORRUPTED, "corrupted regexp" }, + { REGERR_CORRUPTION, "regexp corruption" }, + { REGERR_CORRUPTED_POINTERS, "corrupted pointers" }, + { REGERR_BAD_REGREPEAT, "internal error: bad call of regrepeat" }, + { REGERR_CORRUPTED_OPCODE, "corrupted opcode" }, + { REGERR_NULL_TO_REGSUB, "NULL parm to regsub" }, + { REGERR_DAMAGED_REGEXP_REGSUB, "damaged regexp fed to regsub" }, + { REGERR_DAMAGED_MATCH_STRING, "damaged match string" }, + { REGERR_NULL_TO_REGCOMP, "NULL argument to regcomp" }, + { REGERR_TO_BIG, "regexp too big" }, + { REGERR_TO_MANY_PAREN, "too many ()" }, + { REGERR_UNTERMINATED_PAREN, "unterminated ()" }, + { REGERR_UNMATCHED_PAREN, "unmatched ()" }, + { REGERR_INTERNAL_ERROR_JUNK, "internal error: junk on end" }, + { REGERR_OP_COULD_BE_EMPTY, "*+ operand could be empty" }, + { REGERR_NESTED_OP, "nested *?+" }, + { REGERR_INVALID_RANGE, "invalid [] range" }, + { REGERR_UNMATCHED_BRACE, "unmatched []" }, + { REGERR_INTERNAL_UNEXPECTED_CHAR, "internal error: \\0|) unexpected" }, + { REGERR_OP_FOLLOWS_NOTHING, "?+* follows nothing" }, + { REGERR_TRAILING_ESC, "trailing \\" }, + { REGERR_INTERNAL_STRSCSPN, "internal error: strcspn 0" }, + { REGERR_NO_REGEXP, "NULL regexp" }, + { REGERR_SENTINEL_VALUE, "Unknown error" } // must be last value +}; + +// Flags to be passed up and down. + +enum { + HASWIDTH = 01, // Known never to match null string. + SIMPLE = 02, // Simple enough to be STAR/PLUS operand. + SPSTART = 04, // Starts with * or +. + WORST = 0 // Worst case. +}; + +/////////////////////////////////////////////////////////////////////////////// + +class CRegErrorHandler +{ + friend Regexp; + mutable string m_szError; + static const char * FindErr( int id ); +protected: + void ClearErrorString() const; + void regerror( const char * s ) const; + void regerror( int id ) const; +public: + CRegErrorHandler() { } + CRegErrorHandler( const CRegErrorHandler & reh ) : m_szError( reh.m_szError ) {} + + const string & GetErrorString() const; +}; + +void CRegErrorHandler::regerror( const char * s ) const +{ + TRACE( "regerror: %s\n", s ); + m_szError = s; +} + +void CRegErrorHandler::regerror( int id ) const +{ + regerror( FindErr( id ) ); +} + +const string & CRegErrorHandler::GetErrorString() const +{ + return m_szError; +} + +void CRegErrorHandler::ClearErrorString() const +{ + m_szError = "" ; +} + +const char * CRegErrorHandler::FindErr( int id ) +{ + for ( struct regErr * perr = errors; perr->m_id != REGERR_SENTINEL_VALUE; perr++ ) + if ( perr->m_id == id ) + return perr->m_err; + + return perr->m_err; // since we've fallen off the array, perr->m_id == 0 +} + +/////////////////////////////////////////////////////////////////////////////// + +// All of the functions required to directly access the 'program' +class CRegProgramAccessor : public CRegErrorHandler +{ +public: + static inline char OP( char * p ) + { + return (*(p)); + } + static inline char * OPERAND( char * p ) + { + return p + 3; + } + static inline char * regnext( char * p ) + { + const short &offset = *((short*)(p+1)); + + if (offset == 0) + return(NULL); + + return((OP(p) == BACK) ? p-offset : p+offset); + } +#ifdef _RE_DEBUG + char * CRegProgramAccessor::regprop( char * op ); +#endif +}; + +/////////////////////////////////////////////////////////////////////////////// + +// The internal interface to the regexp, wrapping the compilation as well as the +// execution of the regexp (matching) + +class regexp : public CRegProgramAccessor +{ + friend class CRegExecutor; + friend class Regexp; + + int m_programSize; + char * startp[Regexp::NSUBEXP]; + char * endp[Regexp::NSUBEXP]; + char regstart; // Internal use only. + char reganch; // Internal use only. + char * regmust; // Internal use only. + int regmlen; // Internal use only. + char * program; + + bool status; + int count; // used by Regexp to manage the reference counting of regexps + int numSubs; +public: + + regexp( const char * exp, bool iCase ); + regexp( const regexp & r ); + ~regexp(); + + void ignoreCase( const char * in, char * out ); + + bool regcomp( const char * exp ); + bool regexec( const char * string ); + bool Status() const { return status; } + + string GetReplaceString( const char* sReplaceExp ) const; + + regexp * getCopy(); + +#ifdef _RE_DEBUG + void regdump(); +#endif + +#ifdef _DEBUG + string m_originalPattern; + string m_modifiedPattern; +#endif +}; + +/////////////////////////////////////////////////////////////////////////////// +// Compile / Validate the regular expression - ADT + +class CRegCompilerBase : public CRegProgramAccessor +{ +public: + CRegCompilerBase( const char * parse ); + + char * reg(int paren, int *flagp); +protected: + char * regparse; // Input-scan pointer. + int regnpar; // () count. + + char * regbranch(int *flagp); + char * regpiece(int *flagp); + char * regatom(int *flagp); + inline bool ISREPN( char c ) { return ((c) == '*' || (c) == '+' || (c) == '?'); } + + virtual void regc(int c) = 0; + virtual char * regnode(int op) = 0; + virtual void reginsert(char op, char * opnd) = 0; + virtual void regtail(char * p, char * val) = 0; + virtual void regoptail(char * p, char * val) = 0; +}; + +/////////////////////////////////////////////////////////////////////////////// +// First pass over the expression, testing for validity and returning the +// program size + +class CRegValidator : public CRegCompilerBase +{ +public: + CRegValidator( const char * parse ); + + inline long Size() const { return regsize; } +private: + long regsize; // Code size. + char regdummy[3]; // NOTHING, 0 next ptr +protected: + char * regnode(int) { regsize += 3; return regdummy; } + void regc(int) { regsize++; } + void reginsert(char, char *) { regsize += 3; } + void regtail(char *, char *) { return; } + void regoptail(char *, char *) { return; } +}; + +/////////////////////////////////////////////////////////////////////////////// +// Second pass, actually generating the program + +class CRegCompiler : public CRegCompilerBase +{ +public: + CRegCompiler( const char * parse, char * prog ); +private: + char * regcode; +protected: + // regc - emit (if appropriate) a byte of code + void regc(int b) + { + *regcode++ = (char)b; + } + char * regnode(int op); + void reginsert(char op, char * opnd); + void regtail(char * p, char * val); + void regoptail(char * p, char * val); +}; + +// regnode - emit a node +char * CRegCompiler::regnode(int op) +{ + char * const ret = regcode; + + char * ptr = ret; + *ptr++ = (char)op; + *ptr++ = '\0'; // Null next pointer. + *ptr++ = '\0'; + regcode = ptr; + + return(ret); +} + +// reginsert - insert an operator in front of already-emitted operand +// +// Means relocating the operand. +void CRegCompiler::reginsert(char op, char * opnd) +{ + char * place; + + (void) memmove(opnd+3, opnd, (size_t)((regcode - opnd)*sizeof(char))); + regcode += 3; + + place = opnd; // Op node, where operand used to be. + *place++ = op; + *place++ = '\0'; + *place++ = '\0'; +} + +// regtail - set the next-pointer at the end of a node chain +void CRegCompiler::regtail(char * p, char * val) +{ + char * scan; + char * temp; + + // Find last node. + for (scan = p; (temp = regnext(scan)) != NULL; scan = temp) + continue; + + *((short *)(scan+1)) = (short)((OP(scan) == BACK) ? scan - val : val - scan); +} + +// regoptail - regtail on operand of first argument; nop if operandless +void CRegCompiler::regoptail(char * p, char * val) +{ + // "Operandless" and "op != BRANCH" are synonymous in practice. + if (OP(p) == BRANCH) + regtail(OPERAND(p), val); +} + +/////////////////////////////////////////////////////////////////////////////// + +CRegCompilerBase::CRegCompilerBase( const char * parse ) + : regparse( (char *)parse ), + regnpar(1) +{ +} + +CRegValidator::CRegValidator( const char * parse ) + : CRegCompilerBase( parse ), + regsize(0) +{ + regc(MAGIC); + regdummy[0] = NOTHING; + regdummy[1] = regdummy[2] = 0; +} + +CRegCompiler::CRegCompiler( const char * parse, char * prog ) + : CRegCompilerBase( parse ), + regcode(prog) +{ + regc(MAGIC); +} + +/////////////////////////////////////////////////////////////////////////////// + +regexp::regexp( const char * exp, bool iCase ) + : regstart(0), + reganch(0), + regmust(0), + regmlen(0), + program(0), + m_programSize(0) +{ +#if _DEBUG + m_originalPattern = exp; // keep a version of the pattern for debugging +#endif + + if ( iCase ) + { + char * out = new char[(strlen( exp ) * 4) + 1]; + ignoreCase( exp, out ); + +#if _DEBUG + m_modifiedPattern = out; // and the modified version if there is one +#endif + status = regcomp( out ); + delete [] out; + } + else + status = regcomp( exp ); + + count = numSubs = 0; +} + +regexp::regexp( const regexp & orig ) + : regstart(orig.regstart), + reganch(orig.reganch), + regmlen(orig.regmlen), + m_programSize(orig.m_programSize), + numSubs(orig.numSubs), + regmust(0) +{ +#if _DEBUG + m_originalPattern = orig.m_originalPattern; + m_modifiedPattern = orig.m_modifiedPattern; +#endif + status = orig.status; + count = 0; + program = new char[m_programSize]; + memcpy( program, orig.program, m_programSize * sizeof( char ) ); + if ( orig.regmust ) + regmust = program + ( orig.regmust - orig.program ); + + for ( int i = Regexp::NSUBEXP - 1; i >= 0; i--) + { + startp[i] = orig.startp[i]; + endp[i] = orig.endp[i]; + } +} + +regexp::~regexp() +{ + delete [] program; +} + + +// regcomp - compile a regular expression into internal code +// +// We can't allocate space until we know how big the compiled form will +// be, but we can't compile it (and thus know how big it is) until we've +// got a place to put the code. So we cheat: we compile it twice, once +// with code generation turned off and size counting turned on, and once +// "for real". This also means that we don't allocate space until we are +// sure that the thing really will compile successfully, and we never +// have to move the code and thus invalidate pointers into it. (Note +// that it has to be in one piece because free() must be able to free it +// all.) +// +// Beware that the optimization-preparation code in here knows about some +// of the structure of the compiled regexp. + +bool regexp::regcomp(const char * exp) +{ + char * scan; + int flags; + + if (exp == NULL) + { + regerror( REGERR_NULL_TO_REGCOMP ); + return NULL; + } + + // First pass: determine size, legality. + CRegValidator tester( exp ); + + if (tester.reg(0, &flags) == NULL) + return false; + + // Small enough for pointer-storage convention? + if (tester.Size() >= 0x7fffL) // Probably could be 0xffffL. + { + regerror(REGERR_TO_BIG); + return NULL; + } + + m_programSize = tester.Size(); + // Allocate space. + program = new char[m_programSize]; + + CRegCompiler comp( exp, program ); + // Second pass: emit code. + if (comp.reg(0, &flags) == NULL) + return false; + + scan = program + 1; // First BRANCH. + if (OP(regnext(scan)) == END) + { // Only one top-level choice. + scan = OPERAND(scan); + + // Starting-point info. + if (OP(scan) == EXACTLY) + regstart = *OPERAND(scan); + else if (OP(scan) == BOL) + reganch = 1; + + // If there's something expensive in the r.e., find the + // longest literal string that must appear and make it the + // regmust. Resolve ties in favor of later strings, since + // the regstart check works with the beginning of the r.e. + // and avoiding duplication strengthens checking. Not a + // strong reason, but sufficient in the absence of others. + + if (flags&SPSTART) + { + char * longest = NULL; + size_t len = 0; + + for (; scan != NULL; scan = regnext(scan)) + if (OP(scan) == EXACTLY && strlen(OPERAND(scan)) >= len) + { + longest = OPERAND(scan); + len = strlen(OPERAND(scan)); + } + regmust = longest; + regmlen = (int)len; + } + } + + return true; +} + +regexp * regexp::getCopy() +{ + return new regexp( *this ); +} + +// reg - regular expression, i.e. main body or parenthesized thing +// +// Caller must absorb opening parenthesis. +// +// Combining parenthesis handling with the base level of regular expression +// is a trifle forced, but the need to tie the tails of the branches to what +// follows makes it hard to avoid. + +char * CRegCompilerBase::reg( int paren, int *flagp ) +{ + char * ret = NULL; + char * br; + char * ender; + int parno = 0; + int flags; + + *flagp = HASWIDTH; // Tentatively. + + if (paren) + { + // Make an OPEN node. + if (regnpar >= Regexp::NSUBEXP) + { + regerror(REGERR_TO_MANY_PAREN); + return NULL; + } + parno = regnpar; + regnpar++; + ret = regnode(OPEN+parno); + } + + // Pick up the branches, linking them together. + br = regbranch(&flags); + if (br == NULL) + return(NULL); + if (paren) + regtail(ret, br); // OPEN -> first. + else + ret = br; + *flagp &= ~(~flags&HASWIDTH); // Clear bit if bit 0. + *flagp |= flags&SPSTART; + while (*regparse == '|') + { + regparse++; + br = regbranch(&flags); + if (br == NULL) + return(NULL); + regtail(ret, br); // BRANCH -> BRANCH. + *flagp &= ~(~flags&HASWIDTH); + *flagp |= flags&SPSTART; + } + + // Make a closing node, and hook it on the end. + ender = regnode((paren) ? CLOSE+parno : END); + regtail(ret, ender); + + // Hook the tails of the branches to the closing node. + for (br = ret; br != NULL; br = regnext(br)) + regoptail(br, ender); + + // Check for proper termination. + if (paren && *regparse++ != ')') + { + regerror( REGERR_UNTERMINATED_PAREN ); + return NULL; + } + else if (!paren && *regparse != '\0') + { + if (*regparse == ')') + { + regerror( REGERR_UNMATCHED_PAREN ); + return NULL; + } + else + { + regerror( REGERR_INTERNAL_ERROR_JUNK ); + return NULL; + } + // NOTREACHED + } + + return(ret); +} + +// regbranch - one alternative of an | operator +// +// Implements the concatenation operator. + +char * CRegCompilerBase::regbranch(int *flagp) +{ + char * ret; + char * chain; + char * latest; + int flags; + int c; + + *flagp = WORST; // Tentatively. + + ret = regnode(BRANCH); + chain = NULL; + while ((c = *regparse) != '\0' && c != '|' && c != ')') + { + latest = regpiece(&flags); + if (latest == NULL) + return(NULL); + *flagp |= flags&HASWIDTH; + if (chain == NULL) // First piece. + *flagp |= flags&SPSTART; + else + regtail(chain, latest); + chain = latest; + } + if (chain == NULL) // Loop ran zero times. + (void) regnode(NOTHING); + + return(ret); +} + +// regpiece - something followed by possible [*+?] +// +// Note that the branching code sequences used for ? and the general cases +// of * and + are somewhat optimized: they use the same NOTHING node as +// both the endmarker for their branch list and the body of the last branch. +// It might seem that this node could be dispensed with entirely, but the +// endmarker role is not redundant. + +char * CRegCompilerBase::regpiece(int *flagp) +{ + char * ret; + char op; + char * next; + int flags; + + ret = regatom(&flags); + if (ret == NULL) + return(NULL); + + op = *regparse; + if (!ISREPN(op)) + { + *flagp = flags; + return(ret); + } + + if (!(flags&HASWIDTH) && op != '?' ) + { + regerror( REGERR_OP_COULD_BE_EMPTY ); + return NULL; + } + switch (op) + { + case '*' : *flagp = WORST|SPSTART; break; + case '+' : *flagp = WORST|SPSTART|HASWIDTH; break; + case '?' : *flagp = WORST; break; + } + + if (op == '*' && (flags&SIMPLE)) + reginsert(STAR, ret); + else if (op == '*' ) + { + // Emit x* as (x&|), where & means "self". + reginsert(BRANCH, ret); // Either x + regoptail(ret, regnode(BACK)); // and loop + regoptail(ret, ret); // back + regtail(ret, regnode(BRANCH)); // or + regtail(ret, regnode(NOTHING)); // null. + } + else if (op == '+' && (flags&SIMPLE)) + reginsert(PLUS, ret); + else if (op == '+' ) + { + // Emit x+ as x(&|), where & means "self". + next = regnode(BRANCH); // Either + regtail(ret, next); + regtail(regnode(BACK), ret); // loop back + regtail(next, regnode(BRANCH)); // or + regtail(ret, regnode(NOTHING)); // null. + } + else if (op == '?' ) + { + // Emit x? as (x|) + reginsert(BRANCH, ret); // Either x + regtail(ret, regnode(BRANCH)); // or + next = regnode(NOTHING); // null. + regtail(ret, next); + regoptail(ret, next); + } + regparse++; + if (ISREPN(*regparse)) + { + regerror( REGERR_NESTED_OP ); + return NULL; + } + + return(ret); +} + +// regatom - the lowest level +// +// Optimization: gobbles an entire sequence of ordinary characters so that +// it can turn them into a single node, which is smaller to store and +// faster to run. Backslashed characters are exceptions, each becoming a +// separate node; the code is simpler that way and it's not worth fixing. + +char * CRegCompilerBase::regatom(int * flagp) +{ + char * ret; + int flags; + + *flagp = WORST; // Tentatively. + + switch ( *regparse++ ) + { + // FIXME: these chars only have meaning at beg/end of pat? + case '^': + ret = regnode(BOL); + break; + case '$': + ret = regnode(EOL); + break; + case '.': + ret = regnode(ANY); + *flagp |= HASWIDTH|SIMPLE; + break; + case '[': + { + int range; + int rangeend; + int c; + + if (*regparse == '^') + { // Complement of range. + ret = regnode(ANYBUT); + regparse++; + } + else + ret = regnode(ANYOF); + if ((c = *regparse) == ']' || c == '-') + { + regc(c); + regparse++; + } + while ((c = *regparse++ ) != '\0' && c != ']') + { + if (c != '-') + regc(c); + else if ((c = *regparse) == ']' || c == '\0') + regc('-'); + else + { + range = (char)*(regparse-2); + rangeend = (char)c; + if (range > rangeend) + { + regerror( REGERR_INVALID_RANGE ); + return NULL; + } + for (range++; range <= rangeend; range++) + regc(range); + regparse++; + } + } + regc('\0'); + if (c != ']') + { + regerror( REGERR_UNMATCHED_BRACE ); + return NULL; + } + *flagp |= HASWIDTH|SIMPLE; + break; + } + case '(': + ret = reg(1, &flags); + if (ret == NULL) + return(NULL); + *flagp |= flags&(HASWIDTH|SPSTART); + break; + case '\0': + case '|': + case ')': + // supposed to be caught earlier + regerror( REGERR_INTERNAL_UNEXPECTED_CHAR ); + return NULL; + case '?': + case '+': + case '*': + { + regerror( REGERR_OP_FOLLOWS_NOTHING ); + return NULL; + } + case '\\': + switch (*regparse++) + { + case '\0': + { + regerror( REGERR_TRAILING_ESC ); + return NULL; + } + case '<': + ret = regnode(WORDA); + break; + case '>': + ret = regnode(WORDZ); + break; + /* FIXME: Someday handle \1, \2, ... */ + default: + /* Handle general quoted chars in exact-match routine */ + goto de_fault; + } + break; + de_fault: + default: + // Encode a string of characters to be matched exactly. + // + // This is a bit tricky due to quoted chars and due to + // '*', '+', and '?' taking the SINGLE char previous + // as their operand. + // + // On entry, the char at regparse[-1] is going to go + // into the string, no matter what it is. (It could be + // following a \ if we are entered from the '\' case.) + // + // Basic idea is to pick up a good char in ch and + // examine the next char. If it's *+? then we twiddle. + // If it's \ then we frozzle. If it's other magic char + // we push ch and terminate the string. If none of the + // above, we push ch on the string and go around again. + // + // regprev is used to remember where "the current char" + // starts in the string, if due to a *+? we need to back + // up and put the current char in a separate, 1-char, string. + // When regprev is NULL, ch is the only char in the + // string; this is used in *+? handling, and in setting + // flags |= SIMPLE at the end. + { + char *regprev; + register char ch; + + regparse--; /* Look at cur char */ + ret = regnode(EXACTLY); + for ( regprev = 0 ; ; ) { + ch = *regparse++; /* Get current char */ + switch (*regparse) { /* look at next one */ + + default: + regc(ch); /* Add cur to string */ + break; + + case '.': case '[': case '(': + case ')': case '|': case '\n': + case '$': case '^': + case '\0': + /* FIXME, $ and ^ should not always be magic */ + magic: + regc(ch); /* dump cur char */ + goto done; /* and we are done */ + + case '?': case '+': case '*': + if (!regprev) /* If just ch in str, */ + goto magic; /* use it */ + /* End mult-char string one early */ + regparse = regprev; /* Back up parse */ + goto done; + + case '\\': + regc(ch); /* Cur char OK */ + switch (regparse[1]){ /* Look after \ */ + case '\0': + case '<': + case '>': + /* FIXME: Someday handle \1, \2, ... */ + goto done; /* Not quoted */ + default: + /* Backup point is \, scan * point is after it. */ + regprev = regparse; + regparse++; + continue; /* NOT break; */ + } + } + regprev = regparse; /* Set backup point */ + } + done: + regc('\0'); + *flagp |= HASWIDTH; + if (!regprev) /* One char? */ + *flagp |= SIMPLE; + } + break; + } + + return(ret); +} + +//////////////////////////////////////////////////////////////////////////////// +// regexec and friends + +// Work-variable struct for regexec(). + +class CRegExecutor : public CRegProgramAccessor +{ + friend bool regexp::regexec( const char * str ); + + char * reginput; // String-input pointer. + char * regbol; // Beginning of input, for ^ check. + char * * regstartp; // Pointer to startp array. + char * * regendp; // Ditto for endp. + + regexp * prog; +public: + CRegExecutor( regexp * prog, char * string ); +protected: + bool regtry( char * string ); + bool regmatch( char * prog ); + size_t regrepeat( char * node ); +}; + +CRegExecutor::CRegExecutor( regexp * p, char * string ) + : regbol( string ), + regstartp( p->startp ), + regendp( p->endp ), + prog(p) +{ +} + +#ifdef _RE_DEBUG +int regnarrate = 0; +#endif + +// regexec - match a regexp against a string + +bool regexp::regexec( const char * str ) +{ + char * string = (char *)str; // avert const poisoning + + // Be paranoid. + if ( string == NULL ) + { + regerror( REGERR_NULLARG ); + return false; + } + + // Check validity of program. + if (*program != MAGIC) + { + regerror( REGERR_CORRUPTED ); + return false; + } + + // If there is a "must appear" string, look for it. + if ( regmust != NULL && strstr( string, regmust ) == NULL ) + return false; + + CRegExecutor executor( this, string ); + + // Simplest case: anchored match need be tried only once. + if ( reganch ) + return( executor.regtry( string ) ); + + // Messy cases: unanchored match. + if ( regstart != '\0' ) + { + // We know what char it must start with. + for ( char * s = string; s != NULL; s = strchr( s+1 , regstart ) ) + if ( executor.regtry( s) ) + return true; + return false; + } + else + { + // We don't -- general case. + for ( char * s = string; ! executor.regtry( s ); s++ ) + if (*s == '\0') + return false; + } + return true; +} + +// regtry - try match at specific point +bool CRegExecutor::regtry( char * string ) +{ + int i; + char * * stp; + char * * enp; + + reginput = string; + + stp = prog->startp; + enp = prog->endp; + for (i = Regexp::NSUBEXP; i > 0; i--) + { + *stp++ = NULL; + *enp++ = NULL; + } + if ( regmatch( prog->program + 1 ) ) + { + prog->startp[0] = string; + prog->endp[0] = reginput; + return true; + } + else + return false; +} + +// regmatch - main matching routine +// +// Conceptually the strategy is simple: check to see whether the current +// node matches, call self recursively to see whether the rest matches, +// and then act accordingly. In practice we make some effort to avoid +// recursion, in particular by going through "ordinary" nodes (that don't +// need to know whether the rest of the match failed) by a loop instead of +// by recursion. + +bool CRegExecutor::regmatch( char * prog ) +{ + char * scan; // Current node. + char * next; // Next node. + +#ifdef _RE_DEBUG + if (prog != NULL && regnarrate) + fprintf(stderr, "%s(\n", regprop(prog)); +#endif + for (scan = prog; scan != NULL; scan = next) + { +#ifdef _RE_DEBUG + if (regnarrate) + fprintf(stderr, "%s...\n", regprop(scan)); +#endif + next = regnext(scan); + + switch (OP(scan)) + { + case BOL: + if (reginput != regbol) + return false; + break; + case EOL: + if (*reginput != '\0') + return false; + break; + case WORDA: + /* Must be looking at a letter, digit, or _ */ + if ((!isalnum(*reginput)) && *reginput != '_') + return(0); + /* Prev must be BOL or nonword */ + if (reginput > regbol && + (isalnum(reginput[-1]) || reginput[-1] == '_')) + return(0); + break; + case WORDZ: + /* Must be looking at non letter, digit, or _ */ + if (isalnum(*reginput) || *reginput == '_') + return(0); + /* We don't care what the previous char was */ + break; + case ANY: + if (*reginput == '\0') + return false; + reginput++; + break; + case EXACTLY: + { + size_t len; + char * const opnd = OPERAND(scan); + + // Inline the first character, for speed. + if (*opnd != *reginput) + return false; + len = strlen(opnd); + if (len > 1 && strncmp(opnd, reginput, len) != 0) + return false; + reginput += len; + + break; + } + case ANYOF: + if (*reginput == '\0' || + strchr(OPERAND(scan), *reginput) == NULL) + return false; + reginput++; + break; + case ANYBUT: + if (*reginput == '\0' || + strchr(OPERAND(scan), *reginput) != NULL) + return false; + reginput++; + break; + case NOTHING: + break; + case BACK: + break; + case OPEN+1: case OPEN+2: case OPEN+3: + case OPEN+4: case OPEN+5: case OPEN+6: + case OPEN+7: case OPEN+8: case OPEN+9: + case OPEN+10: case OPEN+11: case OPEN+12: + case OPEN+13: case OPEN+14: case OPEN+15: + case OPEN+16: case OPEN+17: case OPEN+18: + case OPEN+19: + { + const int no = OP(scan) - OPEN; + char * const input = reginput; + + if (regmatch(next)) + { + // Don't set startp if some later + // invocation of the same parentheses + // already has. + + if (regstartp[no] == NULL) + regstartp[no] = input; + return true; + } + else + return false; + break; + } + case CLOSE+1: case CLOSE+2: case CLOSE+3: + case CLOSE+4: case CLOSE+5: case CLOSE+6: + case CLOSE+7: case CLOSE+8: case CLOSE+9: + case CLOSE+10: case CLOSE+11: case CLOSE+12: + case CLOSE+13: case CLOSE+14: case CLOSE+15: + case CLOSE+16: case CLOSE+17: case CLOSE+18: + case CLOSE+19: + { + const int no = OP(scan) - CLOSE; + char * const input = reginput; + + if (regmatch(next)) + { + // Don't set endp if some later + // invocation of the same parentheses + // already has. + + if (regendp[no] == NULL) + regendp[no] = input; + return true; + } + else + return false; + break; + } + case BRANCH: + { + char * const save = reginput; + + if (OP(next) != BRANCH) // No choice. + next = OPERAND(scan); // Avoid recursion. + else + { + while (OP(scan) == BRANCH) + { + if (regmatch(OPERAND(scan))) + return true; + reginput = save; + scan = regnext(scan); + } + return false; + // NOTREACHED + } + break; + } + case STAR: case PLUS: + { + const char nextch = (OP(next) == EXACTLY) ? *OPERAND(next) : '\0'; + size_t no; + char * const save = reginput; + const size_t min = (OP(scan) == STAR) ? 0 : 1; + + for (no = regrepeat(OPERAND(scan)) + 1; no > min; no--) + { + reginput = save + no - 1; + // If it could work, try it. + if (nextch == '\0' || *reginput == nextch) + if (regmatch(next)) + return true; + } + return false; + break; + } + case END: + return true; // Success! + break; + default: + regerror( REGERR_CORRUPTION ); + return false; + break; + } + } + + // We get here only if there's trouble -- normally "case END" is + // the terminating point. + + regerror( REGERR_CORRUPTED_POINTERS ); + return false; +} + +// regrepeat - report how many times something simple would match + +size_t CRegExecutor::regrepeat( char * node ) +{ + size_t count; + char * scan; + char ch; + + switch (OP(node)) + { + case ANY: + return(strlen(reginput)); + break; + case EXACTLY: + ch = *OPERAND(node); + count = 0; + for (scan = reginput; *scan == ch; scan++) + count++; + return(count); + break; + case ANYOF: + return(strspn(reginput, OPERAND(node))); + break; + case ANYBUT: + return(strcspn(reginput, OPERAND(node))); + break; + default: // Oh dear. Called inappropriately. + regerror( REGERR_BAD_REGREPEAT ); + return(0); // Best compromise. + break; + } + // NOTREACHED +} + +#ifdef _RE_DEBUG + +// regdump - dump a regexp onto stdout in vaguely comprehensible form + +void regexp::regdump() +{ + char * s; + char op = EXACTLY; // Arbitrary non-END op. + char * next; + + s = program + 1; + while (op != END) + { // While that wasn't END last time... + op = OP(s); + printf("%2d%s", s-program, regprop(s)); // Where, what. + next = regnext(s); + if (next == NULL) // Next ptr. + printf("(0)" ); + else + printf("(%d)", (s-program)+(next-s)); + s += 3; + if (op == ANYOF || op == ANYBUT || op == EXACTLY) + { + // Literal string, where present. + while (*s != '\0') + { + putchar(*s); + s++; + } + s++; + } + putchar('\n'); + } + + // Header fields of interest. + if (regstart != '\0') + printf("start `%c' ", regstart); + if (reganch) + printf("anchored "); + if (regmust != NULL) + printf("must have \"%s\"" , regmust); + printf("\n"); +} + +// regprop - printable representation of opcode + +#define OUTPUT(s) case s: p = #s; break +char * CRegProgramAccessor::regprop( char * op ) +{ + char * p = NULL; + static char buf[50]; + + (void) strcpy(buf, ":" ); + + switch (OP(op)) + { + OUTPUT( BOL ); + OUTPUT( EOL ); + OUTPUT( ANY ); + OUTPUT( ANYOF ); + OUTPUT( ANYBUT ); + OUTPUT( BRANCH ); + OUTPUT( EXACTLY ); + OUTPUT( NOTHING ); + OUTPUT( BACK ); + OUTPUT( END ); + OUTPUT( STAR ); + OUTPUT( PLUS ); + OUTPUT( WORDA ); + OUTPUT( WORDZ ); + case OPEN+1: case OPEN+2: case OPEN+3: + case OPEN+4: case OPEN+5: case OPEN+6: + case OPEN+7: case OPEN+8: case OPEN+9: + case OPEN+10: case OPEN+11: case OPEN+12: + case OPEN+13: case OPEN+14: case OPEN+15: + case OPEN+16: case OPEN+17: case OPEN+18: + case OPEN+19: + sprintf(buf+strlen(buf), "OPEN%d", OP(op)-OPEN); + p = NULL; + break; + case CLOSE+1: case CLOSE+2: case CLOSE+3: + case CLOSE+4: case CLOSE+5: case CLOSE+6: + case CLOSE+7: case CLOSE+8: case CLOSE+9: + case CLOSE+10: case CLOSE+11: case CLOSE+12: + case CLOSE+13: case CLOSE+14: case CLOSE+15: + case CLOSE+16: case CLOSE+17: case CLOSE+18: + case CLOSE+19: + sprintf(buf+strlen(buf), "CLOSE%d", OP(op)-CLOSE); + p = NULL; + break; + default: + regerror( REGERR_CORRUPTED_OPCODE ); + break; + } + if (p != NULL) + (void) strcat(buf, p); + return(buf); +} +#endif + +/////////////////////////////////////////////////////////////////////////////// + +Regexp::Regexp() + : rc(0), + str(0) +{ +} + +Regexp::Regexp( const char * exp, bool iCase ) + : rc( new regexp( exp, iCase ) ), + str( 0 ) +{ +} + +Regexp::Regexp( const Regexp &r ) + : rc( r.rc ), + m_szError(r.m_szError), + str(r.str) +{ + if ( rc ) + rc->count++; +} + +const Regexp & Regexp::operator=( const Regexp & r ) +{ + if ( this != &r ) + { + if ( rc && rc->count-- == 0 ) + delete rc; + + rc = r.rc; + if ( rc ) + rc->count++; + + str = r.str; + m_szError = r.m_szError; + } + return *this; +} + +Regexp::~Regexp() +{ + if ( rc && rc->count-- == 0 ) + delete rc; +} + +bool Regexp::Match( const char * s ) +{ + ClearErrorString(); + str = s; + bool ret = false; + if ( rc ) + { + // copy on write ! + + if ( rc->count ) + { + rc->count--; + rc = rc->getCopy(); + } + + ret = rc->regexec( s ); + int i = 0; + if ( ret ) + for ( i = 0; i < Regexp::NSUBEXP && rc->startp[i] ; i++ ) + ; + rc->numSubs = i - 1; + } + else + m_szError = CRegErrorHandler::FindErr( REGERR_NO_REGEXP ); + return ret; +} + +string Regexp::GetReplaceString( const char * source ) const +{ + ClearErrorString(); + if ( rc ) + return rc->GetReplaceString( source ); + else + m_szError = CRegErrorHandler::FindErr( REGERR_NO_REGEXP ); + return ""; +} + +int Regexp::SubStrings() const +{ + ClearErrorString(); + int ret = -1; + if ( rc ) + ret = rc->numSubs; + else + m_szError = CRegErrorHandler::FindErr( REGERR_NO_REGEXP ); + return ret; +} + +int Regexp::SubStart( unsigned int i ) const +{ + ClearErrorString(); + int ret = -1; + if ( rc ) + ret = rc->startp[safeIndex(i)] - str; + else + m_szError = CRegErrorHandler::FindErr( REGERR_NO_REGEXP ); + return ret; +} + +int Regexp::SubLength( unsigned int i ) const +{ + ClearErrorString(); + int ret = -1; + if ( rc ) + { + i = safeIndex(i); + ret = rc->endp[i] - rc->startp[i]; + } + else + m_szError = CRegErrorHandler::FindErr( REGERR_NO_REGEXP ); + return ret; +} + +bool Regexp::CompiledOK() const +{ + return rc ? rc->Status() : false; +} + +#ifdef _RE_DEBUG +void Regexp::Dump() +{ + if ( rc ) + rc->regdump(); +#if defined( _DEBUG ) + else + TRACE( "No regexp to dump out\n" ); +#endif +} +#endif + +int Regexp::safeIndex( unsigned int i ) const +{ + return i < Regexp::NSUBEXP ? i : Regexp::NSUBEXP; +} + +const string Regexp::operator[]( unsigned int i ) const +{ + string value; + ClearErrorString(); + assert( rc ); + if ( rc ) + { + int len = SubLength(i); + //char * szbuf = buffer.GetBufferSetLength( len ); + //memcpy( szbuf, rc->startp[i], len * sizeof(char) ); + //buffer.ReleaseBuffer(); + value = std::string ( rc->startp[i], len ); + } + else + { + m_szError = CRegErrorHandler::FindErr( REGERR_NO_REGEXP ); + } + return value; +} + +void regexp::ignoreCase( const char * in, char * out ) +{ + // copy in to out making every top level character a [Aa] set + bool inRange = false; + while( *in ) + { + if ( *in == '[' ) + inRange = true; + if ( *in == ']' ) + inRange = false; + if ( ! inRange && isalpha( *in ) ) + { + *out++ = '['; + *out++ = (char)toupper( *in ); + *out++ = (char)tolower( *in ); + *out++ = ']'; + } + else + *out++ = *in; + in++; + } + *out = 0; +} + +// GetReplaceString - Converts a replace expression to a string +// - perform substitutions after a regexp match +// Returns - The resultant string +string regexp::GetReplaceString( const char* sReplaceExp ) const +{ + string szEmpty( "" ); + + char *src = (char *)sReplaceExp; + //char *buf; + char c; + int no; + size_t len; + + if( sReplaceExp == NULL ) + { + regerror( REGERR_NULL_TO_REGSUB ); + return szEmpty; + } + if ( *program != MAGIC) + { + regerror( REGERR_DAMAGED_REGEXP_REGSUB ); + return szEmpty; + } + + // First compute the length of the string + int replacelen = 0; + while ((c = *src++) != '\0') + { + if (c == '&') + no = 0; + else if (c == '\\' && isdigit(*src)) + no = *src++ - '0'; + else + no = -1; + + if (no < 0) + { + // Ordinary character. + if (c == '\\' && (*src == '\\' || *src == '&')) + c = *src++; + replacelen++; + } + else if (startp[no] != NULL && endp[no] != NULL && + endp[no] > startp[no]) + { + // Get tagged expression + len = endp[no] - startp[no]; + replacelen += len; + } + } + + string szReplace; + + //buf = szReplace.GetBufferSetLength( replacelen ); + + // Now we can create the string + src = (char *)sReplaceExp; + while ((c = *src++) != '\0') + { + if (c == '&') + no = 0; + else if (c == '\\' && isdigit(*src)) + no = *src++ - '0'; + else + no = -1; + + if (no < 0) + { + // Ordinary character. + if (c == '\\' && (*src == '\\' || *src == '&')) + c = *src++; + //*buf++ = c; + szReplace += c ; + } + else if (startp[no] != NULL && endp[no] != NULL && + endp[no] > startp[no]) + { + // Get tagged expression + len = endp[no] - startp[no]; + //strncpy(buf, startp[no], len); + //buf += len; + szReplace.append( startp[no], len ); +// if (len != 0 && *(buf-1) == '\0' )) +// { /* strncpy hit NUL. */ +// regerror( REGERR_DAMAGED_MATCH_STRING ); +// return szEmpty; +// } + } + } + + //szReplace.ReleaseBuffer( replacelen ); + return szReplace; +} + +string Regexp::GetErrorString() const +{ + // make sure that if status == 0 that we have an error string + assert( ( ! CompiledOK() ) ? ( rc ? rc->GetErrorString() : m_szError).length() != 0 : 1 ); + return rc ? rc->GetErrorString() : m_szError ; +} + +void Regexp::ClearErrorString() const +{ + if ( rc ) + rc->ClearErrorString(); + m_szError.erase(); +} + -- cgit v1.1 From 4e12afd9ab0ea2c3f798e14664fe626b3b0adc9d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:16 +0000 Subject: Utilisateur : Fcolin Date : 28/06/00 Heure : 11:59 Archivé dans $/Ivy (vss 2) --- Ivy/Regexp.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx index 6d44def..8671411 100644 --- a/Ivy/Regexp.cxx +++ b/Ivy/Regexp.cxx @@ -250,7 +250,7 @@ const string & CRegErrorHandler::GetErrorString() const void CRegErrorHandler::ClearErrorString() const { - m_szError = "" ; + m_szError.erase() ; } const char * CRegErrorHandler::FindErr( int id ) -- cgit v1.1 From 0d3dc16714e986e3a2720b64ad451bb24596485a Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:18 +0000 Subject: Utilisateur : Fcolin Date : 30/11/00 Heure : 15:35 Archivé dans $/Ivy Commentaire: suppression de l'assert en cas d'erreur de compile regexp (vss 3) --- Ivy/Regexp.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx index 8671411..049a22c 100644 --- a/Ivy/Regexp.cxx +++ b/Ivy/Regexp.cxx @@ -1744,7 +1744,7 @@ string regexp::GetReplaceString( const char* sReplaceExp ) const string Regexp::GetErrorString() const { // make sure that if status == 0 that we have an error string - assert( ( ! CompiledOK() ) ? ( rc ? rc->GetErrorString() : m_szError).length() != 0 : 1 ); + //assert( ( ! CompiledOK() ) ? ( rc ? rc->GetErrorString() : m_szError).length() != 0 : 1 ); return rc ? rc->GetErrorString() : m_szError ; } -- cgit v1.1 From 2463a4b909e35d2312bdffbae124e3edc542cc8c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:20 +0000 Subject: Utilisateur : Fcolin Date : 23/01/01 Heure : 13:12 Archivé dans $/Ivy Commentaire: remove 'using name space std;' (vss 4) --- Ivy/Regexp.cxx | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx index 049a22c..01f3d45 100644 --- a/Ivy/Regexp.cxx +++ b/Ivy/Regexp.cxx @@ -219,7 +219,7 @@ enum { class CRegErrorHandler { friend Regexp; - mutable string m_szError; + mutable String m_szError; static const char * FindErr( int id ); protected: void ClearErrorString() const; @@ -229,7 +229,7 @@ public: CRegErrorHandler() { } CRegErrorHandler( const CRegErrorHandler & reh ) : m_szError( reh.m_szError ) {} - const string & GetErrorString() const; + const String & GetErrorString() const; }; void CRegErrorHandler::regerror( const char * s ) const @@ -243,7 +243,7 @@ void CRegErrorHandler::regerror( int id ) const regerror( FindErr( id ) ); } -const string & CRegErrorHandler::GetErrorString() const +const String & CRegErrorHandler::GetErrorString() const { return m_szError; } @@ -324,7 +324,7 @@ public: bool regexec( const char * string ); bool Status() const { return status; } - string GetReplaceString( const char* sReplaceExp ) const; + String GetReplaceString( const char* sReplaceExp ) const; regexp * getCopy(); @@ -333,8 +333,8 @@ public: #endif #ifdef _DEBUG - string m_originalPattern; - string m_modifiedPattern; + String m_originalPattern; + String m_modifiedPattern; #endif }; @@ -1535,7 +1535,7 @@ bool Regexp::Match( const char * s ) return ret; } -string Regexp::GetReplaceString( const char * source ) const +String Regexp::GetReplaceString( const char * source ) const { ClearErrorString(); if ( rc ) @@ -1603,9 +1603,9 @@ int Regexp::safeIndex( unsigned int i ) const return i < Regexp::NSUBEXP ? i : Regexp::NSUBEXP; } -const string Regexp::operator[]( unsigned int i ) const +const String Regexp::operator[]( unsigned int i ) const { - string value; + String value; ClearErrorString(); assert( rc ); if ( rc ) @@ -1650,9 +1650,9 @@ void regexp::ignoreCase( const char * in, char * out ) // GetReplaceString - Converts a replace expression to a string // - perform substitutions after a regexp match // Returns - The resultant string -string regexp::GetReplaceString( const char* sReplaceExp ) const +String regexp::GetReplaceString( const char* sReplaceExp ) const { - string szEmpty( "" ); + String szEmpty( "" ); char *src = (char *)sReplaceExp; //char *buf; @@ -1698,7 +1698,7 @@ string regexp::GetReplaceString( const char* sReplaceExp ) const } } - string szReplace; + String szReplace; //buf = szReplace.GetBufferSetLength( replacelen ); @@ -1741,7 +1741,7 @@ string regexp::GetReplaceString( const char* sReplaceExp ) const return szReplace; } -string Regexp::GetErrorString() const +String Regexp::GetErrorString() const { // make sure that if status == 0 that we have an error string //assert( ( ! CompiledOK() ) ? ( rc ? rc->GetErrorString() : m_szError).length() != 0 : 1 ); -- cgit v1.1 From 7bbc8b43b4901cd8cddb5a8cd0cc2246d4f45529 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:22 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 5) --- Ivy/Regexp.cxx | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx index 01f3d45..ebade4e 100644 --- a/Ivy/Regexp.cxx +++ b/Ivy/Regexp.cxx @@ -219,7 +219,7 @@ enum { class CRegErrorHandler { friend Regexp; - mutable String m_szError; + mutable string m_szError; static const char * FindErr( int id ); protected: void ClearErrorString() const; @@ -229,7 +229,7 @@ public: CRegErrorHandler() { } CRegErrorHandler( const CRegErrorHandler & reh ) : m_szError( reh.m_szError ) {} - const String & GetErrorString() const; + const string & GetErrorString() const; }; void CRegErrorHandler::regerror( const char * s ) const @@ -243,7 +243,7 @@ void CRegErrorHandler::regerror( int id ) const regerror( FindErr( id ) ); } -const String & CRegErrorHandler::GetErrorString() const +const string & CRegErrorHandler::GetErrorString() const { return m_szError; } @@ -324,7 +324,7 @@ public: bool regexec( const char * string ); bool Status() const { return status; } - String GetReplaceString( const char* sReplaceExp ) const; + string GetReplaceString( const char* sReplaceExp ) const; regexp * getCopy(); @@ -333,8 +333,8 @@ public: #endif #ifdef _DEBUG - String m_originalPattern; - String m_modifiedPattern; + string m_originalPattern; + string m_modifiedPattern; #endif }; @@ -1035,7 +1035,7 @@ class CRegExecutor : public CRegProgramAccessor { friend bool regexp::regexec( const char * str ); - char * reginput; // String-input pointer. + char * reginput; // string-input pointer. char * regbol; // Beginning of input, for ^ check. char * * regstartp; // Pointer to startp array. char * * regendp; // Ditto for endp. @@ -1535,7 +1535,7 @@ bool Regexp::Match( const char * s ) return ret; } -String Regexp::GetReplaceString( const char * source ) const +string Regexp::GetReplaceString( const char * source ) const { ClearErrorString(); if ( rc ) @@ -1603,18 +1603,18 @@ int Regexp::safeIndex( unsigned int i ) const return i < Regexp::NSUBEXP ? i : Regexp::NSUBEXP; } -const String Regexp::operator[]( unsigned int i ) const +const string Regexp::operator[]( unsigned int i ) const { - String value; + string value; ClearErrorString(); - assert( rc ); + ASSERT( rc ); if ( rc ) { int len = SubLength(i); //char * szbuf = buffer.GetBufferSetLength( len ); //memcpy( szbuf, rc->startp[i], len * sizeof(char) ); //buffer.ReleaseBuffer(); - value = std::string ( rc->startp[i], len ); + value = string ( rc->startp[i], len ); } else { @@ -1650,9 +1650,9 @@ void regexp::ignoreCase( const char * in, char * out ) // GetReplaceString - Converts a replace expression to a string // - perform substitutions after a regexp match // Returns - The resultant string -String regexp::GetReplaceString( const char* sReplaceExp ) const +string regexp::GetReplaceString( const char* sReplaceExp ) const { - String szEmpty( "" ); + string szEmpty( "" ); char *src = (char *)sReplaceExp; //char *buf; @@ -1698,7 +1698,7 @@ String regexp::GetReplaceString( const char* sReplaceExp ) const } } - String szReplace; + string szReplace; //buf = szReplace.GetBufferSetLength( replacelen ); @@ -1741,7 +1741,7 @@ String regexp::GetReplaceString( const char* sReplaceExp ) const return szReplace; } -String Regexp::GetErrorString() const +string Regexp::GetErrorString() const { // make sure that if status == 0 that we have an error string //assert( ( ! CompiledOK() ) ? ( rc ? rc->GetErrorString() : m_szError).length() != 0 : 1 ); -- cgit v1.1 From 2fd4b6c291350eb8f2e19d2ef7741e98956ab74d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:24 +0000 Subject: Utilisateur : Fcolin Date : 19/02/01 Heure : 17:00 Archivé dans $/Ivy (vss 6) --- Ivy/Regexp.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx index ebade4e..af667d3 100644 --- a/Ivy/Regexp.cxx +++ b/Ivy/Regexp.cxx @@ -278,7 +278,7 @@ public: } static inline char * regnext( char * p ) { - const short &offset = *((short*)(p+1)); + const short offset = *((short*)(p+1)); if (offset == 0) return(NULL); -- cgit v1.1 From 03e474e496e7a9e7918c1d7abe0b358ebdc3a63f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:26 +0000 Subject: Utilisateur : Fcolin Date : 16/07/01 Heure : 11:47 Archivé dans $/Ivy (vss 7) --- Ivy/Regexp.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx index af667d3..37de17c 100644 --- a/Ivy/Regexp.cxx +++ b/Ivy/Regexp.cxx @@ -1,7 +1,7 @@ // Win32 porting notes. #if defined( _MBCS ) -#pragma message( __FILEINFO__ "This code is broken under _MBCS, " \ +#pragma message( __FILE__ "This code is broken under _MBCS, " \ "see the comments at the top of this file." ) #endif //_MBCS // -- cgit v1.1 From 78c293ac5257f15176fb9e9a8c654e0102077a9f Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:28 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:45 Archivé dans $/Bus/Ivy Commentaire: (vss 8) --- Ivy/Regexp.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx index 37de17c..bcbbf0c 100644 --- a/Ivy/Regexp.cxx +++ b/Ivy/Regexp.cxx @@ -67,7 +67,7 @@ // precedence is structured in regular expressions. Serious changes in // regular-expression syntax might require a total rethink. -#include "stdafx.h" +#include "IvyStdAfx.h" #include "regexp.h" // The first byte of the regexp internal "program" is actually this magic -- cgit v1.1 From d7cd3e3c39b076075935168087e153383e455dab Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:30 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 9) --- Ivy/Regexp.cxx | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx index bcbbf0c..4ba60e3 100644 --- a/Ivy/Regexp.cxx +++ b/Ivy/Regexp.cxx @@ -219,7 +219,7 @@ enum { class CRegErrorHandler { friend Regexp; - mutable string m_szError; + mutable ivy::string m_szError; static const char * FindErr( int id ); protected: void ClearErrorString() const; @@ -229,7 +229,7 @@ public: CRegErrorHandler() { } CRegErrorHandler( const CRegErrorHandler & reh ) : m_szError( reh.m_szError ) {} - const string & GetErrorString() const; + const ivy::string & GetErrorString() const; }; void CRegErrorHandler::regerror( const char * s ) const @@ -243,7 +243,7 @@ void CRegErrorHandler::regerror( int id ) const regerror( FindErr( id ) ); } -const string & CRegErrorHandler::GetErrorString() const +const ivy::string & CRegErrorHandler::GetErrorString() const { return m_szError; } @@ -324,7 +324,7 @@ public: bool regexec( const char * string ); bool Status() const { return status; } - string GetReplaceString( const char* sReplaceExp ) const; + ivy::string GetReplaceString( const char* sReplaceExp ) const; regexp * getCopy(); @@ -333,8 +333,8 @@ public: #endif #ifdef _DEBUG - string m_originalPattern; - string m_modifiedPattern; + ivy::string m_originalPattern; + ivy::string m_modifiedPattern; #endif }; @@ -1535,7 +1535,7 @@ bool Regexp::Match( const char * s ) return ret; } -string Regexp::GetReplaceString( const char * source ) const +ivy::string Regexp::GetReplaceString( const char * source ) const { ClearErrorString(); if ( rc ) @@ -1603,9 +1603,9 @@ int Regexp::safeIndex( unsigned int i ) const return i < Regexp::NSUBEXP ? i : Regexp::NSUBEXP; } -const string Regexp::operator[]( unsigned int i ) const +const ivy::string Regexp::operator[]( unsigned int i ) const { - string value; + ivy::string value; ClearErrorString(); ASSERT( rc ); if ( rc ) @@ -1614,7 +1614,7 @@ const string Regexp::operator[]( unsigned int i ) const //char * szbuf = buffer.GetBufferSetLength( len ); //memcpy( szbuf, rc->startp[i], len * sizeof(char) ); //buffer.ReleaseBuffer(); - value = string ( rc->startp[i], len ); + value = ivy::string ( rc->startp[i], len ); } else { @@ -1650,9 +1650,9 @@ void regexp::ignoreCase( const char * in, char * out ) // GetReplaceString - Converts a replace expression to a string // - perform substitutions after a regexp match // Returns - The resultant string -string regexp::GetReplaceString( const char* sReplaceExp ) const +ivy::string regexp::GetReplaceString( const char* sReplaceExp ) const { - string szEmpty( "" ); + ivy::string szEmpty( "" ); char *src = (char *)sReplaceExp; //char *buf; @@ -1698,7 +1698,7 @@ string regexp::GetReplaceString( const char* sReplaceExp ) const } } - string szReplace; + ivy::string szReplace; //buf = szReplace.GetBufferSetLength( replacelen ); @@ -1741,7 +1741,7 @@ string regexp::GetReplaceString( const char* sReplaceExp ) const return szReplace; } -string Regexp::GetErrorString() const +ivy::string Regexp::GetErrorString() const { // make sure that if status == 0 that we have an error string //assert( ( ! CompiledOK() ) ? ( rc ? rc->GetErrorString() : m_szError).length() != 0 : 1 ); -- cgit v1.1 From ea575235ff3f2029061c0bfc5de2e452490d1d43 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:32 +0000 Subject: Utilisateur : Fcolin Date : 23/09/05 Heure : 15:27 Archivé dans $/Bus/Ivy Commentaire: (vss 10) --- Ivy/Regexp.cxx | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx index 4ba60e3..5916ec8 100644 --- a/Ivy/Regexp.cxx +++ b/Ivy/Regexp.cxx @@ -1556,10 +1556,10 @@ int Regexp::SubStrings() const return ret; } -int Regexp::SubStart( unsigned int i ) const +size_t Regexp::SubStart( size_t i ) const { ClearErrorString(); - int ret = -1; + size_t ret = -1; if ( rc ) ret = rc->startp[safeIndex(i)] - str; else @@ -1567,10 +1567,10 @@ int Regexp::SubStart( unsigned int i ) const return ret; } -int Regexp::SubLength( unsigned int i ) const +size_t Regexp::SubLength( size_t i ) const { ClearErrorString(); - int ret = -1; + size_t ret = -1; if ( rc ) { i = safeIndex(i); @@ -1598,19 +1598,19 @@ void Regexp::Dump() } #endif -int Regexp::safeIndex( unsigned int i ) const +size_t Regexp::safeIndex( size_t i ) const { return i < Regexp::NSUBEXP ? i : Regexp::NSUBEXP; } -const ivy::string Regexp::operator[]( unsigned int i ) const +const ivy::string Regexp::operator[]( size_t i ) const { ivy::string value; ClearErrorString(); ASSERT( rc ); if ( rc ) { - int len = SubLength(i); + size_t len = SubLength(i); //char * szbuf = buffer.GetBufferSetLength( len ); //memcpy( szbuf, rc->startp[i], len * sizeof(char) ); //buffer.ReleaseBuffer(); @@ -1672,7 +1672,7 @@ ivy::string regexp::GetReplaceString( const char* sReplaceExp ) const } // First compute the length of the string - int replacelen = 0; + size_t replacelen = 0; while ((c = *src++) != '\0') { if (c == '&') -- cgit v1.1 From e6dbff317adc5b2dc6d174128f3f9d6177cf1207 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:34 +0000 Subject: Utilisateur : Fcolin Date : 23/09/05 Heure : 15:51 Archivé dans $/Bus/Ivy Commentaire: (vss 11) --- Ivy/Regexp.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx index 5916ec8..4dc1823 100644 --- a/Ivy/Regexp.cxx +++ b/Ivy/Regexp.cxx @@ -255,7 +255,8 @@ void CRegErrorHandler::ClearErrorString() const const char * CRegErrorHandler::FindErr( int id ) { - for ( struct regErr * perr = errors; perr->m_id != REGERR_SENTINEL_VALUE; perr++ ) + struct regErr * perr; + for ( perr = errors; perr->m_id != REGERR_SENTINEL_VALUE; perr++ ) if ( perr->m_id == id ) return perr->m_err; -- cgit v1.1 From 3f3f2e621789c3c65eb10d3ee937c047c5a46857 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:37 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/Regexp.h | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 Ivy/Regexp.h (limited to 'Ivy') diff --git a/Ivy/Regexp.h b/Ivy/Regexp.h new file mode 100644 index 0000000..22e2699 --- /dev/null +++ b/Ivy/Regexp.h @@ -0,0 +1,44 @@ +#ifndef __REGEXP_H__ +#define __REGEXP_H__ + + +class regexp; + +class Regexp +{ +public: + enum { NSUBEXP = 20 }; + + Regexp(); + Regexp( const char * exp, bool iCase = 0 ); + Regexp( const Regexp &r ); + ~Regexp(); + const Regexp & operator=( const Regexp & r ); + + bool Match( const char * s ); + int SubStrings() const; + + const string operator[]( unsigned int i ) const; + int SubStart( unsigned int i ) const; + int SubLength( unsigned int i ) const; + + string GetReplaceString( const char * source ) const; + + string GetErrorString() const; + bool CompiledOK() const; + +#if defined( _RE_DEBUG ) + void Dump(); +#endif +private: + const char * str; /* used to return substring offsets only */ + mutable string m_szError; + regexp * rc; + + void ClearErrorString() const; + int safeIndex( unsigned int i ) const; + +}; + +#endif + -- cgit v1.1 From 00a296093ba62e3fcabc50a23f864424a8ca5af2 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:38 +0000 Subject: Utilisateur : Fcolin Date : 23/01/01 Heure : 13:12 Archivé dans $/Ivy Commentaire: remove 'using name space std;' (vss 2) --- Ivy/Regexp.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.h b/Ivy/Regexp.h index 22e2699..3265561 100644 --- a/Ivy/Regexp.h +++ b/Ivy/Regexp.h @@ -18,13 +18,13 @@ public: bool Match( const char * s ); int SubStrings() const; - const string operator[]( unsigned int i ) const; + const String operator[]( unsigned int i ) const; int SubStart( unsigned int i ) const; int SubLength( unsigned int i ) const; - string GetReplaceString( const char * source ) const; + String GetReplaceString( const char * source ) const; - string GetErrorString() const; + String GetErrorString() const; bool CompiledOK() const; #if defined( _RE_DEBUG ) @@ -32,7 +32,7 @@ public: #endif private: const char * str; /* used to return substring offsets only */ - mutable string m_szError; + mutable String m_szError; regexp * rc; void ClearErrorString() const; -- cgit v1.1 From 5cbed4b3ece796dc63e8958342643fc8a3216051 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:40 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 3) --- Ivy/Regexp.h | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.h b/Ivy/Regexp.h index 3265561..cf7a748 100644 --- a/Ivy/Regexp.h +++ b/Ivy/Regexp.h @@ -1,6 +1,4 @@ -#ifndef __REGEXP_H__ -#define __REGEXP_H__ - +#pragma once class regexp; @@ -18,13 +16,13 @@ public: bool Match( const char * s ); int SubStrings() const; - const String operator[]( unsigned int i ) const; + const string operator[]( unsigned int i ) const; int SubStart( unsigned int i ) const; int SubLength( unsigned int i ) const; - String GetReplaceString( const char * source ) const; + string GetReplaceString( const char * source ) const; - String GetErrorString() const; + string GetErrorString() const; bool CompiledOK() const; #if defined( _RE_DEBUG ) @@ -32,7 +30,7 @@ public: #endif private: const char * str; /* used to return substring offsets only */ - mutable String m_szError; + mutable string m_szError; regexp * rc; void ClearErrorString() const; @@ -40,5 +38,4 @@ private: }; -#endif -- cgit v1.1 From 910fbcd6d06367da9e53ec628a66e86b11b95fef Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:42 +0000 Subject: Utilisateur : Fcolin Date : 19/06/02 Heure : 14:05 Archivé dans $/Ivy Commentaire: Modif nb sub expression de 2à a 40 (vss 4) --- Ivy/Regexp.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.h b/Ivy/Regexp.h index cf7a748..242d1de 100644 --- a/Ivy/Regexp.h +++ b/Ivy/Regexp.h @@ -5,7 +5,7 @@ class regexp; class Regexp { public: - enum { NSUBEXP = 20 }; + enum { NSUBEXP = 40 }; Regexp(); Regexp( const char * exp, bool iCase = 0 ); -- cgit v1.1 From 3206d022a755ffe703964afe2240146127b3f7a4 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:44 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 5) --- Ivy/Regexp.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.h b/Ivy/Regexp.h index 242d1de..3e036d9 100644 --- a/Ivy/Regexp.h +++ b/Ivy/Regexp.h @@ -16,13 +16,13 @@ public: bool Match( const char * s ); int SubStrings() const; - const string operator[]( unsigned int i ) const; + const ivy::string operator[]( unsigned int i ) const; int SubStart( unsigned int i ) const; int SubLength( unsigned int i ) const; - string GetReplaceString( const char * source ) const; + ivy::string GetReplaceString( const char * source ) const; - string GetErrorString() const; + ivy::string GetErrorString() const; bool CompiledOK() const; #if defined( _RE_DEBUG ) @@ -30,7 +30,7 @@ public: #endif private: const char * str; /* used to return substring offsets only */ - mutable string m_szError; + mutable ivy::string m_szError; regexp * rc; void ClearErrorString() const; -- cgit v1.1 From e18ab55cb4a3605cb44f39e829970f7fbd705107 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:46 +0000 Subject: Utilisateur : Fcolin Date : 23/09/05 Heure : 15:27 Archivé dans $/Bus/Ivy Commentaire: (vss 6) --- Ivy/Regexp.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.h b/Ivy/Regexp.h index 3e036d9..b41d88e 100644 --- a/Ivy/Regexp.h +++ b/Ivy/Regexp.h @@ -16,9 +16,9 @@ public: bool Match( const char * s ); int SubStrings() const; - const ivy::string operator[]( unsigned int i ) const; - int SubStart( unsigned int i ) const; - int SubLength( unsigned int i ) const; + const ivy::string operator[]( size_t i ) const; + size_t SubStart( size_t i ) const; + size_t SubLength( size_t i ) const; ivy::string GetReplaceString( const char * source ) const; @@ -34,7 +34,7 @@ private: regexp * rc; void ClearErrorString() const; - int safeIndex( unsigned int i ) const; + size_t safeIndex( size_t i ) const; }; -- cgit v1.1 From d42a6937e7b9eba39de3c7d8edc975499d1f43ff Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:49 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/ThreadedSocket.cxx | 439 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 439 insertions(+) create mode 100644 Ivy/ThreadedSocket.cxx (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx new file mode 100644 index 0000000..f00e6f5 --- /dev/null +++ b/Ivy/ThreadedSocket.cxx @@ -0,0 +1,439 @@ +// ThreadedSocket.cpp: implementation of the CThreadedSocket class. +// +////////////////////////////////////////////////////////////////////// + +#include "stdafx.h" +#include + +#include "ThreadedSocket.h" + + +// Class CThreadedSocketException +//IMPLEMENT_DYNAMIC(CThreadedSocketException, CException) + +CThreadedSocketException::CThreadedSocketException(char* pchMessage) +{ + m_strMessage = pchMessage; + m_nError = WSAGetLastError(); +} + +bool CThreadedSocketException::GetErrorMessage(string & lpstrError, UINT nMaxError, + PUINT pnHelpContext /*= NULL*/) +{ + lpstrError = m_strMessage; + lpstrError += "error"; + if(m_nError != 0) + { + lpstrError += " #"; + lpstrError += m_nError; + } + return true; +} + +//IMPLEMENT_DYNAMIC(CThreadedSocket, CObject) + +bool CThreadedSocket::Initialized = false; + +void CThreadedSocket::Init() +{ + WORD wVersionRequested; + WSADATA wsaData; + int err; + + wVersionRequested = MAKEWORD( 2, 2 ); + + err = WSAStartup( wVersionRequested, &wsaData ); + if ( err != 0 ) { + /* Tell the user that we could not find a usable */ + /* WinSock DLL. */ + return; + } + Initialized = true; +} + +////////////////////////////////////////////////////////////////////// +// Construction/Destruction +////////////////////////////////////////////////////////////////////// + +CThreadedSocket::CThreadedSocket() +{ + if ( ! Initialized ) Init(); + + m_hSocket = INVALID_SOCKET; + h_thread = NULL; + // Create events to wait on + // for receivier part + m_hEvent[0] = WSACreateEvent(); + if ( m_hEvent[0] == WSA_INVALID_EVENT ) + { + TRACE( "CThreadedSocketException(WSACreateEvent )\n"); + throw( new CThreadedSocketException( "WSACreateEvent" )); + } + // for transmitter part + m_hEvent[1] = WSACreateEvent(); + if ( m_hEvent[1] == WSA_INVALID_EVENT ) + { + TRACE( "CThreadedSocketException(WSACreateEvent )\n"); + throw( new CThreadedSocketException( "WSACreateEvent" )); + } +} + +CThreadedSocket::~CThreadedSocket() +{ + if (m_hSocket != INVALID_SOCKET) + Close(); + //if ( thread ) // On fait de l'auto delete mais dans le cas de terminaison anormale l'object reste ????!!! + // delete thread; + WSACloseEvent( m_hEvent[0] ); + WSACloseEvent( m_hEvent[1] ); +} +void CThreadedSocket::Create(UINT nSocketPort, int nSocketType, + long lEvent, const char * lpszSocketAddress) +{ + Socket(nSocketType, lEvent); + Bind(nSocketPort,lpszSocketAddress); +} + +///////////////////////////////////////////////////////////////////////////// +// CThreadedSocket Attributes + + + +void CThreadedSocket::GetPeerName(string & rPeerAddress, UINT& rPeerPort) +{ + SOCKADDR_IN sockAddr; + memset(&sockAddr, 0, sizeof(sockAddr)); + + int nSockAddrLen = sizeof(sockAddr); + GetPeerName((SOCKADDR*)&sockAddr, &nSockAddrLen); + rPeerPort = ntohs(sockAddr.sin_port); + rPeerAddress = inet_ntoa(sockAddr.sin_addr); +} + +void CThreadedSocket::GetSockName(string & rSocketAddress, UINT& rSocketPort) +{ + SOCKADDR_IN sockAddr; + memset(&sockAddr, 0, sizeof(sockAddr)); + + int nSockAddrLen = sizeof(sockAddr); + GetSockName((SOCKADDR*)&sockAddr, &nSockAddrLen); + rSocketPort = ntohs(sockAddr.sin_port); + rSocketAddress = inet_ntoa(sockAddr.sin_addr); +} + +///////////////////////////////////////////////////////////////////////////// +// CAscynSocket Operations + +void CThreadedSocket::Accept(CThreadedSocket& rConnectedSocket, + SOCKADDR* lpSockAddr, int* lpSockAddrLen) +{ + assert(rConnectedSocket.m_hSocket == INVALID_SOCKET); + + + SOCKET hTemp = accept(m_hSocket, lpSockAddr, lpSockAddrLen); + + if (hTemp == INVALID_SOCKET) + { + rConnectedSocket.m_hSocket = INVALID_SOCKET; + throw( new CThreadedSocketException( "accept" ) ); + } + else + { + rConnectedSocket.m_hSocket = hTemp; + rConnectedSocket.StartListener(m_EventMask); + } +} + +void CThreadedSocket::Bind(UINT nSocketPort, const char * lpszSocketAddress) +{ + + SOCKADDR_IN sockAddr; + memset(&sockAddr,0,sizeof(sockAddr)); + + sockAddr.sin_family = AF_INET; + + if (lpszSocketAddress == NULL) + sockAddr.sin_addr.s_addr = htonl(INADDR_ANY); + else + { + DWORD lResult = inet_addr(lpszSocketAddress); + if (lResult == INADDR_NONE) + { + WSASetLastError(WSAEINVAL); + throw( new CThreadedSocketException( "bind" ) ); + } + sockAddr.sin_addr.s_addr = lResult; + } + + sockAddr.sin_port = htons((u_short)nSocketPort); + + Bind((SOCKADDR*)&sockAddr, sizeof(sockAddr)); +} + +void CThreadedSocket::Close() +{ + if (m_hSocket != INVALID_SOCKET) + { + AsyncSelect(0); + assert(SOCKET_ERROR != closesocket(m_hSocket)); + m_hSocket = INVALID_SOCKET; + //WSASetEvent( m_hEventObject ); + } +} + +bool CThreadedSocket::Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen) +{ + if ( !connect(m_hSocket, lpSockAddr, nSockAddrLen) ) + { + DWORD err = WSAGetLastError(); + if ( err == 0 ) return TRUE; + TRACE( "***************************************Error connect %d\n", err); + if ( err != WSAEWOULDBLOCK ) + return FALSE; + // Wait for connection to complete + TRACE( "***************************************Waiting for connection to complete\n"); + err = WSAWaitForMultipleEvents( 1, m_hEvent, FALSE, WSA_INFINITE, TRUE); + //TRACE( "Thread socket %d wait return %d\n", m_hSocket, err ); + if ( err == WSA_WAIT_FAILED ) + { + return FALSE; + } + + return TRUE; + } + return TRUE; +} + +bool CThreadedSocket::Connect(const char * lpszHostAddress, UINT nHostPort) +{ + + assert(lpszHostAddress != NULL); + + SOCKADDR_IN sockAddr; + memset(&sockAddr,0,sizeof(sockAddr)); + + sockAddr.sin_family = AF_INET; + sockAddr.sin_addr.s_addr = inet_addr(lpszHostAddress); + + if (sockAddr.sin_addr.s_addr == INADDR_NONE) + { + LPHOSTENT lphost; + lphost = gethostbyname(lpszHostAddress); + if (lphost != NULL) + sockAddr.sin_addr.s_addr = ((LPIN_ADDR)lphost->h_addr)->s_addr; + else + { + WSASetLastError(WSAEINVAL); + return FALSE; + } + } + + sockAddr.sin_port = htons((u_short)nHostPort); + + return Connect((SOCKADDR*)&sockAddr, sizeof(sockAddr)); +} + +int CThreadedSocket::Receive(void* lpBuf, int nBufLen, int nFlags) +{ + int lg = recv(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags); + if ( lg == SOCKET_ERROR ) + throw( new CThreadedSocketException( "recv" ) ); + return lg; +} + +int CThreadedSocket::ReceiveFrom(void* lpBuf, int nBufLen, string & rSocketAddress, UINT& rSocketPort, int nFlags) +{ + SOCKADDR_IN sockAddr; + + memset(&sockAddr, 0, sizeof(sockAddr)); + + int nSockAddrLen = sizeof(sockAddr); + int nResult = ReceiveFrom(lpBuf, nBufLen, (SOCKADDR*)&sockAddr, &nSockAddrLen, nFlags); + rSocketPort = ntohs(sockAddr.sin_port); + rSocketAddress = inet_ntoa(sockAddr.sin_addr); + + return nResult; +} + +void CThreadedSocket::Send(const void* lpBuf, int nBufLen, int nFlags) +{ + if ( send(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags) != nBufLen ) + throw( new CThreadedSocketException( "send" ) ); +} + +void CThreadedSocket::SendTo(const void* lpBuf, int nBufLen, UINT nHostPort, const char * lpszHostAddress, int nFlags) +{ + SOCKADDR_IN sockAddr; + + memset(&sockAddr,0,sizeof(sockAddr)); + + sockAddr.sin_family = AF_INET; + + if (lpszHostAddress == NULL) + sockAddr.sin_addr.s_addr = htonl(INADDR_BROADCAST); + else + { + sockAddr.sin_addr.s_addr = inet_addr(lpszHostAddress); + if (sockAddr.sin_addr.s_addr == INADDR_NONE) + { + LPHOSTENT lphost; + lphost = gethostbyname(lpszHostAddress); + if (lphost != NULL) + sockAddr.sin_addr.s_addr = ((LPIN_ADDR)lphost->h_addr)->s_addr; + else + { + WSASetLastError(WSAEINVAL); + throw( new CThreadedSocketException( "SendTo" )); + return; + } + } + } + + sockAddr.sin_port = htons((u_short)nHostPort); + + SendTo(lpBuf, nBufLen, (SOCKADDR*)&sockAddr, sizeof(sockAddr), nFlags); +} +void CThreadedSocket::AsyncSelect(long lEvent) +{ + assert(m_hSocket != INVALID_SOCKET); + if ( WSAEventSelect(m_hSocket, m_hEvent[0], lEvent) ) + throw( new CThreadedSocketException( "WSAEventSelect" )); +} +///////////////////////////////////////////////////////////////////////////// +// CThreadedSocket Overridable callbacks +void CThreadedSocket::OnWakeup() +{ +} +void CThreadedSocket::OnReceive(int /*nErrorCode*/) +{ +} + +void CThreadedSocket::OnSend(int /*nErrorCode*/) +{ +} + +void CThreadedSocket::OnOutOfBandData(int /*nErrorCode*/) +{ +} + +void CThreadedSocket::OnAccept(int /*nErrorCode*/) +{ +} + +void CThreadedSocket::OnConnect(int /*nErrorCode*/) +{ +} + +void CThreadedSocket::OnClose(int /*nErrorCode*/) +{ +} + +///////////////////////////////////////////////////////////////////////////// +// CThreadedSocket Implementation + + +void CThreadedSocket::Socket(int nSocketType, long lEvent, int nProtocolType, int nAddressFormat) +{ + assert(m_hSocket == INVALID_SOCKET); + + m_hSocket = socket(nAddressFormat,nSocketType,nProtocolType); +// m_hSocket = WSASocket ( nAddressFormat, nSocketType,nProtocolType, NULL, 0, 0 ); + + + if (m_hSocket == INVALID_SOCKET) + { + throw( new CThreadedSocketException( "socket" )); + } + StartListener(lEvent); + +} + +void CThreadedSocket::StartListener(long lEvent) +{ + m_EventMask = lEvent; + h_thread = CreateThread(NULL,0,SocketThreadProc, this, 0, &thread_id); + if ( ! h_thread ) + throw( new CThreadedSocketException( "socket listener" )); +} +// Implementation +DWORD WINAPI CThreadedSocket::SocketThreadProc( LPVOID pParam ) +{ + CThreadedSocket* pObject = (CThreadedSocket*)pParam; + + if (pObject == NULL ) + { + throw( new CThreadedSocketException( "bad socket proc" )); + return -1; // if pObject is not valid + } + + return pObject->SocketThread(); +} + +UINT CThreadedSocket::SocketThread( ) +{ + DWORD err; + WSANETWORKEVENTS NetworkEvents; + + AsyncSelect(m_EventMask) ; + while ( m_hSocket != INVALID_SOCKET ) + { + err = WSAWaitForMultipleEvents( 2, m_hEvent, FALSE, WSA_INFINITE, TRUE); + switch ( err ) + { + case WSA_WAIT_FAILED: + TRACE( "CThreadedSocketException(WSAWaitForMultipleEvents )\n"); + throw( new CThreadedSocketException( "WSAWaitForMultipleEvents" )); + return err; + break; + case WSA_WAIT_EVENT_0: + + NetworkEvents.lNetworkEvents=0; + + if ( WSAEnumNetworkEvents ( m_hSocket, m_hEvent[0], &NetworkEvents )) + { + TRACE( "CThreadedSocketException(WSAEnumNetworkEvents )\n"); + throw( new CThreadedSocketException( "WSAEnumNetworkEvents" )); + return -1; + } + + + if ( NetworkEvents.lNetworkEvents & FD_READ ) + OnReceive(NetworkEvents.iErrorCode[ FD_READ_BIT ]); + + if ( NetworkEvents.lNetworkEvents & FD_WRITE ) + OnSend( NetworkEvents.iErrorCode[ FD_WRITE_BIT ] ); + + if ( NetworkEvents.lNetworkEvents & FD_ACCEPT ) + OnAccept( NetworkEvents.iErrorCode[ FD_ACCEPT_BIT ] ); + + + if ( NetworkEvents.lNetworkEvents & FD_CONNECT ) + OnConnect( NetworkEvents.iErrorCode[ FD_CONNECT_BIT ] ); + + if ( NetworkEvents.lNetworkEvents & FD_OOB ) + OnOutOfBandData( NetworkEvents.iErrorCode[ FD_OOB_BIT ] ); + + if ( NetworkEvents.lNetworkEvents & FD_CLOSE ) + { + OnClose( NetworkEvents.iErrorCode[ FD_CLOSE_BIT ] ); + } + + break; + case WSA_WAIT_EVENT_0 +1 : + if ( m_hSocket != INVALID_SOCKET ) + { + OnWakeup(); + } + // else Close by other Thread do silent terminaison + WSAResetEvent( m_hEvent[1] ); + + break; + default: + TRACE( "CThreadedSocket::SocketThread Unhandled Events !\n"); + break; + } + } + Close(); + h_thread = NULL; + return 0; +} -- cgit v1.1 From ff43d6adcef7ed20cf896553ae050f9ee70da412 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:50 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:40 Archivé dans $/Ivy Commentaire: Init dll socket dans DLLMain (vss 2) --- Ivy/ThreadedSocket.cxx | 22 ---------------------- 1 file changed, 22 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index f00e6f5..64df41e 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -30,34 +30,12 @@ bool CThreadedSocketException::GetErrorMessage(string & lpstrError, UINT nMaxErr return true; } -//IMPLEMENT_DYNAMIC(CThreadedSocket, CObject) - -bool CThreadedSocket::Initialized = false; - -void CThreadedSocket::Init() -{ - WORD wVersionRequested; - WSADATA wsaData; - int err; - - wVersionRequested = MAKEWORD( 2, 2 ); - - err = WSAStartup( wVersionRequested, &wsaData ); - if ( err != 0 ) { - /* Tell the user that we could not find a usable */ - /* WinSock DLL. */ - return; - } - Initialized = true; -} - ////////////////////////////////////////////////////////////////////// // Construction/Destruction ////////////////////////////////////////////////////////////////////// CThreadedSocket::CThreadedSocket() { - if ( ! Initialized ) Init(); m_hSocket = INVALID_SOCKET; h_thread = NULL; -- cgit v1.1 From f2abd2f272583782738a190c0d59a05e86a8198a Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:52 +0000 Subject: Utilisateur : Fcolin Date : 29/06/00 Heure : 15:59 Archivé dans $/Ivy Commentaire: Version multicast (vss 3) --- Ivy/ThreadedSocket.cxx | 37 +++++++++++++++++++++++++++++++++++-- 1 file changed, 35 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 64df41e..1e20e8e 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -242,7 +242,7 @@ void CThreadedSocket::Send(const void* lpBuf, int nBufLen, int nFlags) void CThreadedSocket::SendTo(const void* lpBuf, int nBufLen, UINT nHostPort, const char * lpszHostAddress, int nFlags) { SOCKADDR_IN sockAddr; - + memset(&sockAddr,0,sizeof(sockAddr)); sockAddr.sin_family = AF_INET; @@ -266,11 +266,44 @@ void CThreadedSocket::SendTo(const void* lpBuf, int nBufLen, UINT nHostPort, con } } } - + sockAddr.sin_port = htons((u_short)nHostPort); SendTo(lpBuf, nBufLen, (SOCKADDR*)&sockAddr, sizeof(sockAddr), nFlags); } +void CThreadedSocket::AddMember( const char * lpszHostAddress ) +{ + int multicast_ttl = 64; // region + struct ip_mreq imr; + + TRACE("CThreadedSocket::AddMember adding %s\n", lpszHostAddress ); + imr.imr_multiaddr.s_addr = INADDR_ANY; + imr.imr_interface.s_addr = INADDR_ANY; + + if (lpszHostAddress ) + { + imr.imr_multiaddr.s_addr = inet_addr(lpszHostAddress); + if (imr.imr_multiaddr.s_addr == INADDR_NONE) + { + LPHOSTENT lphost; + lphost = gethostbyname(lpszHostAddress); + if (lphost != NULL) + imr.imr_multiaddr.s_addr = ((LPIN_ADDR)lphost->h_addr)->s_addr; + else + { + WSASetLastError(WSAEINVAL); + throw( new CThreadedSocketException( "AddMenber" )); + return; + } + } + } + if ( IN_CLASSD( htonl(imr.imr_multiaddr.s_addr) ) ) + { + SetSockOpt( IP_MULTICAST_TTL, &multicast_ttl, sizeof( multicast_ttl ), IPPROTO_IP ); + SetSockOpt( IP_ADD_MEMBERSHIP, &imr, sizeof( imr ), IPPROTO_IP ); + } + +} void CThreadedSocket::AsyncSelect(long lEvent) { assert(m_hSocket != INVALID_SOCKET); -- cgit v1.1 From cc506f8b04ce0506c75321b4d5a25da3ca550876 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:54 +0000 Subject: Utilisateur : Fcolin Date : 23/01/01 Heure : 13:12 Archivé dans $/Ivy Commentaire: remove 'using name space std;' (vss 4) --- Ivy/ThreadedSocket.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 1e20e8e..5f4c183 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -17,7 +17,7 @@ CThreadedSocketException::CThreadedSocketException(char* pchMessage) m_nError = WSAGetLastError(); } -bool CThreadedSocketException::GetErrorMessage(string & lpstrError, UINT nMaxError, +bool CThreadedSocketException::GetErrorMessage(String & lpstrError, UINT nMaxError, PUINT pnHelpContext /*= NULL*/) { lpstrError = m_strMessage; @@ -77,7 +77,7 @@ void CThreadedSocket::Create(UINT nSocketPort, int nSocketType, -void CThreadedSocket::GetPeerName(string & rPeerAddress, UINT& rPeerPort) +void CThreadedSocket::GetPeerName(String & rPeerAddress, UINT& rPeerPort) { SOCKADDR_IN sockAddr; memset(&sockAddr, 0, sizeof(sockAddr)); @@ -88,7 +88,7 @@ void CThreadedSocket::GetPeerName(string & rPeerAddress, UINT& rPeerPort) rPeerAddress = inet_ntoa(sockAddr.sin_addr); } -void CThreadedSocket::GetSockName(string & rSocketAddress, UINT& rSocketPort) +void CThreadedSocket::GetSockName(String & rSocketAddress, UINT& rSocketPort) { SOCKADDR_IN sockAddr; memset(&sockAddr, 0, sizeof(sockAddr)); @@ -219,7 +219,7 @@ int CThreadedSocket::Receive(void* lpBuf, int nBufLen, int nFlags) return lg; } -int CThreadedSocket::ReceiveFrom(void* lpBuf, int nBufLen, string & rSocketAddress, UINT& rSocketPort, int nFlags) +int CThreadedSocket::ReceiveFrom(void* lpBuf, int nBufLen, String & rSocketAddress, UINT& rSocketPort, int nFlags) { SOCKADDR_IN sockAddr; -- cgit v1.1 From 7c626ebb6751ab4dc1a86d1939cded83dfea70bd Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:56 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 5) --- Ivy/ThreadedSocket.cxx | 37 +++++++++++++++++-------------------- 1 file changed, 17 insertions(+), 20 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 5f4c183..955af12 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -8,16 +8,13 @@ #include "ThreadedSocket.h" -// Class CThreadedSocketException -//IMPLEMENT_DYNAMIC(CThreadedSocketException, CException) - CThreadedSocketException::CThreadedSocketException(char* pchMessage) { m_strMessage = pchMessage; m_nError = WSAGetLastError(); } -bool CThreadedSocketException::GetErrorMessage(String & lpstrError, UINT nMaxError, +bool CThreadedSocketException::GetErrorMessage(string & lpstrError, UINT nMaxError, PUINT pnHelpContext /*= NULL*/) { lpstrError = m_strMessage; @@ -77,7 +74,7 @@ void CThreadedSocket::Create(UINT nSocketPort, int nSocketType, -void CThreadedSocket::GetPeerName(String & rPeerAddress, UINT& rPeerPort) +void CThreadedSocket::GetPeerName(string & rPeerAddress, UINT& rPeerPort) { SOCKADDR_IN sockAddr; memset(&sockAddr, 0, sizeof(sockAddr)); @@ -88,7 +85,7 @@ void CThreadedSocket::GetPeerName(String & rPeerAddress, UINT& rPeerPort) rPeerAddress = inet_ntoa(sockAddr.sin_addr); } -void CThreadedSocket::GetSockName(String & rSocketAddress, UINT& rSocketPort) +void CThreadedSocket::GetSockName(string & rSocketAddress, UINT& rSocketPort) { SOCKADDR_IN sockAddr; memset(&sockAddr, 0, sizeof(sockAddr)); @@ -105,7 +102,7 @@ void CThreadedSocket::GetSockName(String & rSocketAddress, UINT& rSocketPort) void CThreadedSocket::Accept(CThreadedSocket& rConnectedSocket, SOCKADDR* lpSockAddr, int* lpSockAddrLen) { - assert(rConnectedSocket.m_hSocket == INVALID_SOCKET); + ASSERT(rConnectedSocket.m_hSocket == INVALID_SOCKET); SOCKET hTemp = accept(m_hSocket, lpSockAddr, lpSockAddrLen); @@ -153,7 +150,7 @@ void CThreadedSocket::Close() if (m_hSocket != INVALID_SOCKET) { AsyncSelect(0); - assert(SOCKET_ERROR != closesocket(m_hSocket)); + ASSERT(SOCKET_ERROR != closesocket(m_hSocket)); m_hSocket = INVALID_SOCKET; //WSASetEvent( m_hEventObject ); } @@ -164,28 +161,28 @@ bool CThreadedSocket::Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen) if ( !connect(m_hSocket, lpSockAddr, nSockAddrLen) ) { DWORD err = WSAGetLastError(); - if ( err == 0 ) return TRUE; + if ( err == 0 ) return true; TRACE( "***************************************Error connect %d\n", err); if ( err != WSAEWOULDBLOCK ) - return FALSE; + return false; // Wait for connection to complete TRACE( "***************************************Waiting for connection to complete\n"); - err = WSAWaitForMultipleEvents( 1, m_hEvent, FALSE, WSA_INFINITE, TRUE); + err = WSAWaitForMultipleEvents( 1, m_hEvent, false, WSA_INFINITE, true); //TRACE( "Thread socket %d wait return %d\n", m_hSocket, err ); if ( err == WSA_WAIT_FAILED ) { - return FALSE; + return false; } - return TRUE; + return true; } - return TRUE; + return true; } bool CThreadedSocket::Connect(const char * lpszHostAddress, UINT nHostPort) { - assert(lpszHostAddress != NULL); + ASSERT(lpszHostAddress != NULL); SOCKADDR_IN sockAddr; memset(&sockAddr,0,sizeof(sockAddr)); @@ -202,7 +199,7 @@ bool CThreadedSocket::Connect(const char * lpszHostAddress, UINT nHostPort) else { WSASetLastError(WSAEINVAL); - return FALSE; + return false; } } @@ -219,7 +216,7 @@ int CThreadedSocket::Receive(void* lpBuf, int nBufLen, int nFlags) return lg; } -int CThreadedSocket::ReceiveFrom(void* lpBuf, int nBufLen, String & rSocketAddress, UINT& rSocketPort, int nFlags) +int CThreadedSocket::ReceiveFrom(void* lpBuf, int nBufLen, string & rSocketAddress, UINT& rSocketPort, int nFlags) { SOCKADDR_IN sockAddr; @@ -306,7 +303,7 @@ void CThreadedSocket::AddMember( const char * lpszHostAddress ) } void CThreadedSocket::AsyncSelect(long lEvent) { - assert(m_hSocket != INVALID_SOCKET); + ASSERT(m_hSocket != INVALID_SOCKET); if ( WSAEventSelect(m_hSocket, m_hEvent[0], lEvent) ) throw( new CThreadedSocketException( "WSAEventSelect" )); } @@ -345,7 +342,7 @@ void CThreadedSocket::OnClose(int /*nErrorCode*/) void CThreadedSocket::Socket(int nSocketType, long lEvent, int nProtocolType, int nAddressFormat) { - assert(m_hSocket == INVALID_SOCKET); + ASSERT(m_hSocket == INVALID_SOCKET); m_hSocket = socket(nAddressFormat,nSocketType,nProtocolType); // m_hSocket = WSASocket ( nAddressFormat, nSocketType,nProtocolType, NULL, 0, 0 ); @@ -388,7 +385,7 @@ UINT CThreadedSocket::SocketThread( ) AsyncSelect(m_EventMask) ; while ( m_hSocket != INVALID_SOCKET ) { - err = WSAWaitForMultipleEvents( 2, m_hEvent, FALSE, WSA_INFINITE, TRUE); + err = WSAWaitForMultipleEvents( 2, m_hEvent, false, WSA_INFINITE, true); switch ( err ) { case WSA_WAIT_FAILED: -- cgit v1.1 From cf2e43e95c4eb20314f627bd473e4c99d3c3c9e3 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:58 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 6) --- Ivy/ThreadedSocket.cxx | 357 +++++++++++++++++++++++++++++-------------------- 1 file changed, 209 insertions(+), 148 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 955af12..7f36f07 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -3,29 +3,15 @@ ////////////////////////////////////////////////////////////////////// #include "stdafx.h" -#include + +#ifdef _DEBUG +#define DEBUG_NEW new(__FILE__, __LINE__) +#define new DEBUG_NEW +#endif #include "ThreadedSocket.h" -CThreadedSocketException::CThreadedSocketException(char* pchMessage) -{ - m_strMessage = pchMessage; - m_nError = WSAGetLastError(); -} - -bool CThreadedSocketException::GetErrorMessage(string & lpstrError, UINT nMaxError, - PUINT pnHelpContext /*= NULL*/) -{ - lpstrError = m_strMessage; - lpstrError += "error"; - if(m_nError != 0) - { - lpstrError += " #"; - lpstrError += m_nError; - } - return true; -} ////////////////////////////////////////////////////////////////////// // Construction/Destruction @@ -35,22 +21,11 @@ CThreadedSocket::CThreadedSocket() { m_hSocket = INVALID_SOCKET; - h_thread = NULL; - // Create events to wait on - // for receivier part - m_hEvent[0] = WSACreateEvent(); - if ( m_hEvent[0] == WSA_INVALID_EVENT ) - { - TRACE( "CThreadedSocketException(WSACreateEvent )\n"); - throw( new CThreadedSocketException( "WSACreateEvent" )); - } - // for transmitter part - m_hEvent[1] = WSACreateEvent(); - if ( m_hEvent[1] == WSA_INVALID_EVENT ) - { - TRACE( "CThreadedSocketException(WSACreateEvent )\n"); - throw( new CThreadedSocketException( "WSACreateEvent" )); - } + h_reader = NULL; + h_writer = NULL; + listen_mode = false; + connect_pending = true; + send_pending = false; } CThreadedSocket::~CThreadedSocket() @@ -59,14 +34,17 @@ CThreadedSocket::~CThreadedSocket() Close(); //if ( thread ) // On fait de l'auto delete mais dans le cas de terminaison anormale l'object reste ????!!! // delete thread; - WSACloseEvent( m_hEvent[0] ); - WSACloseEvent( m_hEvent[1] ); } -void CThreadedSocket::Create(UINT nSocketPort, int nSocketType, - long lEvent, const char * lpszSocketAddress) +int CThreadedSocket::Create(UINT nSocketPort, int nSocketType, const char * lpszSocketAddress) { - Socket(nSocketType, lEvent); - Bind(nSocketPort,lpszSocketAddress); + if ( Socket(nSocketType) < 0 ) + return SOCKET_ERROR; + + send_count = CreateSemaphore( NULL, 0, 100, NULL); // unnamed semaphore + if (send_count == NULL) + return SOCKET_ERROR; + + return Bind(nSocketPort,lpszSocketAddress); } ///////////////////////////////////////////////////////////////////////////// @@ -99,27 +77,31 @@ void CThreadedSocket::GetSockName(string & rSocketAddress, UINT& rSocketPort) ///////////////////////////////////////////////////////////////////////////// // CAscynSocket Operations -void CThreadedSocket::Accept(CThreadedSocket& rConnectedSocket, +int CThreadedSocket::Accept(CThreadedSocket& rConnectedSocket, SOCKADDR* lpSockAddr, int* lpSockAddrLen) { ASSERT(rConnectedSocket.m_hSocket == INVALID_SOCKET); - SOCKET hTemp = accept(m_hSocket, lpSockAddr, lpSockAddrLen); if (hTemp == INVALID_SOCKET) { rConnectedSocket.m_hSocket = INVALID_SOCKET; - throw( new CThreadedSocketException( "accept" ) ); + return SOCKET_ERROR; } else { rConnectedSocket.m_hSocket = hTemp; - rConnectedSocket.StartListener(m_EventMask); + rConnectedSocket.send_count = CreateSemaphore( NULL, 0, 100, NULL); // unnamed semaphore + if (rConnectedSocket.send_count == NULL) + return SOCKET_ERROR; + + rConnectedSocket.StartListener(); + return hTemp; } } -void CThreadedSocket::Bind(UINT nSocketPort, const char * lpszSocketAddress) +int CThreadedSocket::Bind(UINT nSocketPort, const char * lpszSocketAddress) { SOCKADDR_IN sockAddr; @@ -135,51 +117,57 @@ void CThreadedSocket::Bind(UINT nSocketPort, const char * lpszSocketAddress) if (lResult == INADDR_NONE) { WSASetLastError(WSAEINVAL); - throw( new CThreadedSocketException( "bind" ) ); + return SOCKET_ERROR; } sockAddr.sin_addr.s_addr = lResult; } sockAddr.sin_port = htons((u_short)nSocketPort); - Bind((SOCKADDR*)&sockAddr, sizeof(sockAddr)); + return Bind((SOCKADDR*)&sockAddr, sizeof(sockAddr)); } void CThreadedSocket::Close() { if (m_hSocket != INVALID_SOCKET) { - AsyncSelect(0); ASSERT(SOCKET_ERROR != closesocket(m_hSocket)); m_hSocket = INVALID_SOCKET; - //WSASetEvent( m_hEventObject ); + } } -bool CThreadedSocket::Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen) +int CThreadedSocket::Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen) { - if ( !connect(m_hSocket, lpSockAddr, nSockAddrLen) ) + int ok; + fd_set writefds; + + FD_ZERO(&writefds); + + FD_SET(m_hSocket, &writefds); + + ok = connect(m_hSocket, lpSockAddr, nSockAddrLen); + if ( !ok ) { - DWORD err = WSAGetLastError(); - if ( err == 0 ) return true; + int err = GetLastError(); + if ( err == 0 ) return err; TRACE( "***************************************Error connect %d\n", err); if ( err != WSAEWOULDBLOCK ) - return false; + return -1; // Wait for connection to complete TRACE( "***************************************Waiting for connection to complete\n"); - err = WSAWaitForMultipleEvents( 1, m_hEvent, false, WSA_INFINITE, true); + FD_SET(m_hSocket, &writefds); + err = select( 1, NULL, &writefds, NULL, NULL ); //TRACE( "Thread socket %d wait return %d\n", m_hSocket, err ); - if ( err == WSA_WAIT_FAILED ) - { - return false; - } - - return true; + if ( !err ) + connect_pending = true; + return err; } - return true; + connect_pending = true; + return 0; } -bool CThreadedSocket::Connect(const char * lpszHostAddress, UINT nHostPort) +int CThreadedSocket::Connect(const char * lpszHostAddress, UINT nHostPort) { ASSERT(lpszHostAddress != NULL); @@ -199,7 +187,7 @@ bool CThreadedSocket::Connect(const char * lpszHostAddress, UINT nHostPort) else { WSASetLastError(WSAEINVAL); - return false; + return SOCKET_ERROR; } } @@ -211,8 +199,6 @@ bool CThreadedSocket::Connect(const char * lpszHostAddress, UINT nHostPort) int CThreadedSocket::Receive(void* lpBuf, int nBufLen, int nFlags) { int lg = recv(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags); - if ( lg == SOCKET_ERROR ) - throw( new CThreadedSocketException( "recv" ) ); return lg; } @@ -230,13 +216,12 @@ int CThreadedSocket::ReceiveFrom(void* lpBuf, int nBufLen, string & rSocketAddre return nResult; } -void CThreadedSocket::Send(const void* lpBuf, int nBufLen, int nFlags) +int CThreadedSocket::Send(const void* lpBuf, int nBufLen, int nFlags) { - if ( send(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags) != nBufLen ) - throw( new CThreadedSocketException( "send" ) ); + return send(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags); } -void CThreadedSocket::SendTo(const void* lpBuf, int nBufLen, UINT nHostPort, const char * lpszHostAddress, int nFlags) +int CThreadedSocket::SendTo(const void* lpBuf, int nBufLen, UINT nHostPort, const char * lpszHostAddress, int nFlags) { SOCKADDR_IN sockAddr; @@ -258,17 +243,16 @@ void CThreadedSocket::SendTo(const void* lpBuf, int nBufLen, UINT nHostPort, con else { WSASetLastError(WSAEINVAL); - throw( new CThreadedSocketException( "SendTo" )); - return; + return SOCKET_ERROR; } } } sockAddr.sin_port = htons((u_short)nHostPort); - SendTo(lpBuf, nBufLen, (SOCKADDR*)&sockAddr, sizeof(sockAddr), nFlags); + return SendTo(lpBuf, nBufLen, (SOCKADDR*)&sockAddr, sizeof(sockAddr), nFlags); } -void CThreadedSocket::AddMember( const char * lpszHostAddress ) +int CThreadedSocket::AddMember( const char * lpszHostAddress ) { int multicast_ttl = 64; // region struct ip_mreq imr; @@ -289,8 +273,7 @@ void CThreadedSocket::AddMember( const char * lpszHostAddress ) else { WSASetLastError(WSAEINVAL); - throw( new CThreadedSocketException( "AddMenber" )); - return; + return SOCKET_ERROR; } } } @@ -299,19 +282,11 @@ void CThreadedSocket::AddMember( const char * lpszHostAddress ) SetSockOpt( IP_MULTICAST_TTL, &multicast_ttl, sizeof( multicast_ttl ), IPPROTO_IP ); SetSockOpt( IP_ADD_MEMBERSHIP, &imr, sizeof( imr ), IPPROTO_IP ); } - -} -void CThreadedSocket::AsyncSelect(long lEvent) -{ - ASSERT(m_hSocket != INVALID_SOCKET); - if ( WSAEventSelect(m_hSocket, m_hEvent[0], lEvent) ) - throw( new CThreadedSocketException( "WSAEventSelect" )); + return 0; } + ///////////////////////////////////////////////////////////////////////////// // CThreadedSocket Overridable callbacks -void CThreadedSocket::OnWakeup() -{ -} void CThreadedSocket::OnReceive(int /*nErrorCode*/) { } @@ -340,108 +315,194 @@ void CThreadedSocket::OnClose(int /*nErrorCode*/) // CThreadedSocket Implementation -void CThreadedSocket::Socket(int nSocketType, long lEvent, int nProtocolType, int nAddressFormat) +int CThreadedSocket::Socket(int nSocketType, int nProtocolType, int nAddressFormat) { ASSERT(m_hSocket == INVALID_SOCKET); - m_hSocket = socket(nAddressFormat,nSocketType,nProtocolType); -// m_hSocket = WSASocket ( nAddressFormat, nSocketType,nProtocolType, NULL, 0, 0 ); - + m_hSocket = socket(nAddressFormat,nSocketType,nProtocolType); - if (m_hSocket == INVALID_SOCKET) + if ( m_hSocket < 0 ) { - throw( new CThreadedSocketException( "socket" )); + return m_hSocket; } - StartListener(lEvent); + return StartListener(); +} +int CThreadedSocket::StartListener() +{ + h_reader = CreateThread(NULL,0,SocketReaderProc, this, 0, &reader_id); + return h_reader != NULL ? 0 : SOCKET_ERROR; +} +int CThreadedSocket::StartWriter() +{ + h_writer = CreateThread(NULL,0,SocketWriterProc, this, 0, &writer_id); + return h_writer != NULL ? 0 : SOCKET_ERROR; +} +bool CThreadedSocket::SignalWriter() +{ + long PreviousCount = 0; + int err; + err = ReleaseSemaphore(send_count, 1, &PreviousCount); + TRACE("CThreadedSocket::SignalWriter() PreviousCount = %ld \n", PreviousCount ); + return (err != 0); } -void CThreadedSocket::StartListener(long lEvent) +// Implementation +DWORD WINAPI CThreadedSocket::SocketReaderProc( LPVOID pParam ) { - m_EventMask = lEvent; - h_thread = CreateThread(NULL,0,SocketThreadProc, this, 0, &thread_id); - if ( ! h_thread ) - throw( new CThreadedSocketException( "socket listener" )); + CThreadedSocket* pObject = (CThreadedSocket*)pParam; + + if (pObject == NULL ) + { + return SOCKET_ERROR; // if pObject is not valid + } + + return pObject->SocketReader(); } // Implementation -DWORD WINAPI CThreadedSocket::SocketThreadProc( LPVOID pParam ) +DWORD WINAPI CThreadedSocket::SocketWriterProc( LPVOID pParam ) { CThreadedSocket* pObject = (CThreadedSocket*)pParam; if (pObject == NULL ) { - throw( new CThreadedSocketException( "bad socket proc" )); - return -1; // if pObject is not valid + return SOCKET_ERROR; // if pObject is not valid } - return pObject->SocketThread(); + return pObject->SocketWriter(); } -UINT CThreadedSocket::SocketThread( ) +UINT CThreadedSocket::SocketReader( ) { - DWORD err; - WSANETWORKEVENTS NetworkEvents; + int err; + int sock_err; + unsigned long readcount; + fd_set readfds; + fd_set writefds; + fd_set exceptfds; + + FD_ZERO(&readfds); + FD_ZERO(&writefds); + FD_ZERO(&exceptfds); - AsyncSelect(m_EventMask) ; while ( m_hSocket != INVALID_SOCKET ) { - err = WSAWaitForMultipleEvents( 2, m_hEvent, false, WSA_INFINITE, true); + FD_SET(m_hSocket, &readfds); + if ( connect_pending ) + FD_SET(m_hSocket, &writefds); + FD_SET(m_hSocket, &exceptfds); + + err = select( 1, &readfds, &writefds, &exceptfds, NULL ); + sock_err = GetLastError(); + switch ( err ) { - case WSA_WAIT_FAILED: - TRACE( "CThreadedSocketException(WSAWaitForMultipleEvents )\n"); - throw( new CThreadedSocketException( "WSAWaitForMultipleEvents" )); - return err; + case 0: + TRACE( "CThreadedSocket::SocketThread Unhandled Timeout Event !\n"); break; - case WSA_WAIT_EVENT_0: - - NetworkEvents.lNetworkEvents=0; - - if ( WSAEnumNetworkEvents ( m_hSocket, m_hEvent[0], &NetworkEvents )) - { - TRACE( "CThreadedSocketException(WSAEnumNetworkEvents )\n"); - throw( new CThreadedSocketException( "WSAEnumNetworkEvents" )); - return -1; - } + case SOCKET_ERROR: - - if ( NetworkEvents.lNetworkEvents & FD_READ ) - OnReceive(NetworkEvents.iErrorCode[ FD_READ_BIT ]); - - if ( NetworkEvents.lNetworkEvents & FD_WRITE ) - OnSend( NetworkEvents.iErrorCode[ FD_WRITE_BIT ] ); - - if ( NetworkEvents.lNetworkEvents & FD_ACCEPT ) - OnAccept( NetworkEvents.iErrorCode[ FD_ACCEPT_BIT ] ); - - - if ( NetworkEvents.lNetworkEvents & FD_CONNECT ) - OnConnect( NetworkEvents.iErrorCode[ FD_CONNECT_BIT ] ); + TRACE( "CThreadedSocketException( select )\n"); + Close(); + h_reader = NULL; + return sock_err; + break; + default: - if ( NetworkEvents.lNetworkEvents & FD_OOB ) - OnOutOfBandData( NetworkEvents.iErrorCode[ FD_OOB_BIT ] ); - if ( NetworkEvents.lNetworkEvents & FD_CLOSE ) + if ( FD_ISSET(m_hSocket, &readfds) ) { - OnClose( NetworkEvents.iErrorCode[ FD_CLOSE_BIT ] ); + IOCtl( FIONREAD, &readcount ); + if ( listen_mode ) + OnAccept( sock_err ); + else if ( ! readcount ) + OnClose( sock_err ); + else OnReceive(sock_err); } - break; - case WSA_WAIT_EVENT_0 +1 : - if ( m_hSocket != INVALID_SOCKET ) + if ( FD_ISSET(m_hSocket, &writefds) ) { - OnWakeup(); + if ( connect_pending ) + { + OnConnect( sock_err ); + connect_pending = false; + } } - // else Close by other Thread do silent terminaison - WSAResetEvent( m_hEvent[1] ); - + + if ( FD_ISSET(m_hSocket, &exceptfds) ) + OnOutOfBandData( sock_err ); + + + break; + } + } + Close(); + h_reader = NULL; + return 0; +} + +UINT CThreadedSocket::SocketWriter( ) +{ + int err; + int sock_err; + fd_set writefds; + + FD_ZERO(&writefds); + + + while ( m_hSocket != INVALID_SOCKET ) + { + DWORD dwWaitResult; + + // Wait for message to send + + dwWaitResult = WaitForSingleObject( send_count, INFINITE ); + + switch (dwWaitResult) { + + // The semaphore object was signaled. + case WAIT_OBJECT_0: + // OK to really send the message. + break; + + // Semaphore was nonsignaled, so a time-out occurred. + case WAIT_TIMEOUT: + case WAIT_FAILED: + default: + TRACE( "CThreadedSocketException( SocketWriter WaitForSingleObject )\n"); + Close(); + h_writer = NULL; + return GetLastError(); + break; + } + + FD_SET(m_hSocket, &writefds); + + err = select( 1, NULL, &writefds, NULL, NULL ); + sock_err = GetLastError(); + + switch ( err ) + { + case 0: + TRACE( "CThreadedSocket::SocketThread Unhandled Timeout Event !\n"); + break; + case SOCKET_ERROR: + TRACE( "CThreadedSocketException( select )\n"); + Close(); + h_reader = NULL; + return sock_err; break; default: - TRACE( "CThreadedSocket::SocketThread Unhandled Events !\n"); + + if ( FD_ISSET(m_hSocket, &writefds) ) + { + OnSend( sock_err ); + } + break; } } Close(); - h_thread = NULL; + h_writer = NULL; return 0; } -- cgit v1.1 From 043e12f158bf3abe0b981b2f69c8376338701afc Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:00 +0000 Subject: Utilisateur : Fcolin Date : 14/02/01 Heure : 18:47 Archivé dans $/Ivy (vss 7) --- Ivy/ThreadedSocket.cxx | 79 ++++++++++++++++++++++++++++++++------------------ 1 file changed, 51 insertions(+), 28 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 7f36f07..4f94573 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -30,10 +30,21 @@ CThreadedSocket::CThreadedSocket() CThreadedSocket::~CThreadedSocket() { + long PreviousCount = 0; + int err; if (m_hSocket != INVALID_SOCKET) Close(); //if ( thread ) // On fait de l'auto delete mais dans le cas de terminaison anormale l'object reste ????!!! // delete thread; + TRACE("CThreadedSocket waiting for thread end ...\n"); + if ( h_reader ) WaitForSingleObject( h_reader, INFINITE ); + // wake up writer + if ( h_writer ) + { + err = ReleaseSemaphore(send_count, 1, &PreviousCount); + WaitForSingleObject( h_writer, INFINITE ); + } + TRACE("CThreadedSocket all thread ended\n"); } int CThreadedSocket::Create(UINT nSocketPort, int nSocketType, const char * lpszSocketAddress) { @@ -376,7 +387,7 @@ UINT CThreadedSocket::SocketReader( ) { int err; int sock_err; - unsigned long readcount; + unsigned long readcount = 0; fd_set readfds; fd_set writefds; fd_set exceptfds; @@ -390,6 +401,8 @@ UINT CThreadedSocket::SocketReader( ) FD_SET(m_hSocket, &readfds); if ( connect_pending ) FD_SET(m_hSocket, &writefds); + else + FD_CLR(m_hSocket, &writefds); FD_SET(m_hSocket, &exceptfds); err = select( 1, &readfds, &writefds, &exceptfds, NULL ); @@ -402,8 +415,10 @@ UINT CThreadedSocket::SocketReader( ) break; case SOCKET_ERROR: - TRACE( "CThreadedSocketException( select )\n"); - Close(); + TRACE( "CThreadedSocket::SocketReader( select error thread_id =( %d) )\n",reader_id); + + if (m_hSocket != INVALID_SOCKET) + Close(); h_reader = NULL; return sock_err; break; @@ -436,8 +451,11 @@ UINT CThreadedSocket::SocketReader( ) break; } } - Close(); + if (m_hSocket != INVALID_SOCKET) + Close(); h_reader = NULL; + TRACE( "CThreadedSocket::SocketReader( END thread_id =( 0x%x) )\n",reader_id); + return 0; } @@ -469,40 +487,45 @@ UINT CThreadedSocket::SocketWriter( ) case WAIT_TIMEOUT: case WAIT_FAILED: default: - TRACE( "CThreadedSocketException( SocketWriter WaitForSingleObject )\n"); - Close(); + TRACE( "CThreadedSocket::SocketWriter( WaitForSingleObject error thread_id =( %d) )\n",writer_id); + if (m_hSocket != INVALID_SOCKET) + Close(); h_writer = NULL; return GetLastError(); break; } + if (m_hSocket != INVALID_SOCKET) + { + FD_SET(m_hSocket, &writefds); - FD_SET(m_hSocket, &writefds); - - err = select( 1, NULL, &writefds, NULL, NULL ); - sock_err = GetLastError(); + err = select( 1, NULL, &writefds, NULL, NULL ); + sock_err = GetLastError(); - switch ( err ) - { - case 0: - TRACE( "CThreadedSocket::SocketThread Unhandled Timeout Event !\n"); - break; - case SOCKET_ERROR: - TRACE( "CThreadedSocketException( select )\n"); - Close(); - h_reader = NULL; - return sock_err; - break; - default: - - if ( FD_ISSET(m_hSocket, &writefds) ) - { - OnSend( sock_err ); - } + switch ( err ) + { + case 0: + TRACE( "CThreadedSocket::SocketThread Unhandled Timeout Event !\n"); + break; + case SOCKET_ERROR: + TRACE( "CThreadedSocketException( select )\n"); + Close(); + h_reader = NULL; + return sock_err; + break; + default: + + if ( FD_ISSET(m_hSocket, &writefds) ) + { + OnSend( sock_err ); + } - break; + break; + } } } Close(); h_writer = NULL; + TRACE( "CThreadedSocket::SocketWriter( END thread_id =( 0x%x) )\n",writer_id); + return 0; } -- cgit v1.1 From ddc6e6f2bbcce4a247952f216c6c50478654bb8a Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:02 +0000 Subject: Utilisateur : Fcolin Date : 19/02/01 Heure : 10:39 Archivé dans $/Ivy (vss 8) --- Ivy/ThreadedSocket.cxx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 4f94573..a9a1760 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -36,7 +36,7 @@ CThreadedSocket::~CThreadedSocket() Close(); //if ( thread ) // On fait de l'auto delete mais dans le cas de terminaison anormale l'object reste ????!!! // delete thread; - TRACE("CThreadedSocket waiting for thread end ...\n"); +// TRACE("CThreadedSocket waiting for thread end ...\n"); if ( h_reader ) WaitForSingleObject( h_reader, INFINITE ); // wake up writer if ( h_writer ) @@ -44,7 +44,7 @@ CThreadedSocket::~CThreadedSocket() err = ReleaseSemaphore(send_count, 1, &PreviousCount); WaitForSingleObject( h_writer, INFINITE ); } - TRACE("CThreadedSocket all thread ended\n"); +// TRACE("CThreadedSocket all thread ended\n"); } int CThreadedSocket::Create(UINT nSocketPort, int nSocketType, const char * lpszSocketAddress) { @@ -354,7 +354,7 @@ bool CThreadedSocket::SignalWriter() long PreviousCount = 0; int err; err = ReleaseSemaphore(send_count, 1, &PreviousCount); - TRACE("CThreadedSocket::SignalWriter() PreviousCount = %ld \n", PreviousCount ); +// TRACE("CThreadedSocket::SignalWriter() PreviousCount = %ld \n", PreviousCount ); return (err != 0); } @@ -454,7 +454,7 @@ UINT CThreadedSocket::SocketReader( ) if (m_hSocket != INVALID_SOCKET) Close(); h_reader = NULL; - TRACE( "CThreadedSocket::SocketReader( END thread_id =( 0x%x) )\n",reader_id); +// TRACE( "CThreadedSocket::SocketReader( END thread_id =( 0x%x) )\n",reader_id); return 0; } @@ -525,7 +525,7 @@ UINT CThreadedSocket::SocketWriter( ) } Close(); h_writer = NULL; - TRACE( "CThreadedSocket::SocketWriter( END thread_id =( 0x%x) )\n",writer_id); +// TRACE( "CThreadedSocket::SocketWriter( END thread_id =( 0x%x) )\n",writer_id); return 0; } -- cgit v1.1 From 3a34f0291c92edb20203611e85ba26909db58977 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:04 +0000 Subject: Utilisateur : Fcolin Date : 23/05/01 Heure : 10:25 Archivé dans $/Ivy (vss 9) --- Ivy/ThreadedSocket.cxx | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index a9a1760..d113f8e 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -160,7 +160,7 @@ int CThreadedSocket::Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen) ok = connect(m_hSocket, lpSockAddr, nSockAddrLen); if ( !ok ) { - int err = GetLastError(); + int err = this->GetLastError(); if ( err == 0 ) return err; TRACE( "***************************************Error connect %d\n", err); if ( err != WSAEWOULDBLOCK ) @@ -262,7 +262,7 @@ int CThreadedSocket::SendTo(const void* lpBuf, int nBufLen, UINT nHostPort, cons sockAddr.sin_port = htons((u_short)nHostPort); return SendTo(lpBuf, nBufLen, (SOCKADDR*)&sockAddr, sizeof(sockAddr), nFlags); -} + } int CThreadedSocket::AddMember( const char * lpszHostAddress ) { int multicast_ttl = 64; // region @@ -406,7 +406,7 @@ UINT CThreadedSocket::SocketReader( ) FD_SET(m_hSocket, &exceptfds); err = select( 1, &readfds, &writefds, &exceptfds, NULL ); - sock_err = GetLastError(); + sock_err = this->GetLastError(); switch ( err ) { @@ -427,6 +427,7 @@ UINT CThreadedSocket::SocketReader( ) if ( FD_ISSET(m_hSocket, &readfds) ) { + readcount = 0; IOCtl( FIONREAD, &readcount ); if ( listen_mode ) OnAccept( sock_err ); @@ -491,7 +492,7 @@ UINT CThreadedSocket::SocketWriter( ) if (m_hSocket != INVALID_SOCKET) Close(); h_writer = NULL; - return GetLastError(); + return this->GetLastError(); break; } if (m_hSocket != INVALID_SOCKET) @@ -499,7 +500,7 @@ UINT CThreadedSocket::SocketWriter( ) FD_SET(m_hSocket, &writefds); err = select( 1, NULL, &writefds, NULL, NULL ); - sock_err = GetLastError(); + sock_err = this->GetLastError(); switch ( err ) { -- cgit v1.1 From 7dbb8513b01bb2489b9b9672ea97682ed69610e5 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:06 +0000 Subject: Utilisateur : Fcolin Date : 6/06/01 Heure : 15:50 Archivé dans $/Ivy (vss 10) --- Ivy/ThreadedSocket.cxx | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index d113f8e..1afb304 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -392,6 +392,8 @@ UINT CThreadedSocket::SocketReader( ) fd_set writefds; fd_set exceptfds; + TRACE( "CThreadedSocket::SocketReader( START thread_id =( 0x%x) )\n",reader_id); + FD_ZERO(&readfds); FD_ZERO(&writefds); FD_ZERO(&exceptfds); @@ -466,6 +468,8 @@ UINT CThreadedSocket::SocketWriter( ) int sock_err; fd_set writefds; + TRACE( "CThreadedSocket::SocketWriter( START thread_id =( 0x%x) )\n",writer_id); + FD_ZERO(&writefds); -- cgit v1.1 From 2610a7a99b4bcff0d8faf22695d35f5342ccbdd3 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:08 +0000 Subject: Utilisateur : Fcolin Date : 17/07/01 Heure : 18:25 Archivé dans $/Ivy (vss 11) --- Ivy/ThreadedSocket.cxx | 4 ---- 1 file changed, 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 1afb304..5fa7322 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -4,10 +4,6 @@ #include "stdafx.h" -#ifdef _DEBUG -#define DEBUG_NEW new(__FILE__, __LINE__) -#define new DEBUG_NEW -#endif #include "ThreadedSocket.h" -- cgit v1.1 From 24304c151f70945ab52e52afb2bf120cef7d7020 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:10 +0000 Subject: Utilisateur : Fcolin Date : 13/08/01 Heure : 16:12 Archivé dans $/Ivy (vss 12) --- Ivy/ThreadedSocket.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 5fa7322..10af005 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -348,7 +348,7 @@ int CThreadedSocket::StartWriter() bool CThreadedSocket::SignalWriter() { long PreviousCount = 0; - int err; + BOOL err; err = ReleaseSemaphore(send_count, 1, &PreviousCount); // TRACE("CThreadedSocket::SignalWriter() PreviousCount = %ld \n", PreviousCount ); return (err != 0); -- cgit v1.1 From 0b1b7a6d41bb5a10da80de3d29946e29450b69f4 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:12 +0000 Subject: Utilisateur : Fcolin Date : 14/09/01 Heure : 16:44 Archivé dans $/Ivy Commentaire: correction BUG Ivy socket Listen apres start Listener et regexp_in.resize (vss 13) --- Ivy/ThreadedSocket.cxx | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 10af005..be2bdf0 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -143,6 +143,13 @@ void CThreadedSocket::Close() } } +int CThreadedSocket::Listen(int nConnectionBacklog) +{ + int err = listen(m_hSocket, nConnectionBacklog); + if ( !err ) + listen_mode = true; + return StartListener(); +} int CThreadedSocket::Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen) { @@ -171,7 +178,7 @@ int CThreadedSocket::Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen) return err; } connect_pending = true; - return 0; + return StartListener(); } int CThreadedSocket::Connect(const char * lpszHostAddress, UINT nHostPort) @@ -332,7 +339,8 @@ int CThreadedSocket::Socket(int nSocketType, int nProtocolType, int nAddressForm { return m_hSocket; } - return StartListener(); + return m_hSocket; + //return StartListener(); } int CThreadedSocket::StartListener() -- cgit v1.1 From 3006e231e192a91fa6d132ddc3e483e1c1a31114 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:14 +0000 Subject: Utilisateur : Fcolin Date : 20/09/01 Heure : 9:40 Archivé dans $/Ivy (vss 14) --- Ivy/ThreadedSocket.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index be2bdf0..f14d79a 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -161,7 +161,7 @@ int CThreadedSocket::Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen) FD_SET(m_hSocket, &writefds); ok = connect(m_hSocket, lpSockAddr, nSockAddrLen); - if ( !ok ) + if ( ok != 0 ) { int err = this->GetLastError(); if ( err == 0 ) return err; -- cgit v1.1 From 1c70f693d16840f4afe269239b4c57dd58a914fe Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:16 +0000 Subject: Utilisateur : Fcolin Date : 19/06/02 Heure : 16:45 Archivé dans $/Ivy Commentaire: (vss 15) --- Ivy/ThreadedSocket.cxx | 4 ---- 1 file changed, 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index f14d79a..c93ffa9 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -335,10 +335,6 @@ int CThreadedSocket::Socket(int nSocketType, int nProtocolType, int nAddressForm m_hSocket = socket(nAddressFormat,nSocketType,nProtocolType); - if ( m_hSocket < 0 ) - { - return m_hSocket; - } return m_hSocket; //return StartListener(); } -- cgit v1.1 From 5d015386435c0c79ac5b973cd86d8c74c5d6d326 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:18 +0000 Subject: Utilisateur : Fcolin Date : 27/09/02 Heure : 12:47 Archivé dans $/Ivy Commentaire: (vss 16) --- Ivy/ThreadedSocket.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index c93ffa9..19670f7 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -513,7 +513,7 @@ UINT CThreadedSocket::SocketWriter( ) break; case SOCKET_ERROR: TRACE( "CThreadedSocketException( select )\n"); - Close(); + if (m_hSocket != INVALID_SOCKET) Close(); h_reader = NULL; return sock_err; break; -- cgit v1.1 From 5d97d1f9916d4c8a7880b965200b0d95510e6dfc Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:20 +0000 Subject: Utilisateur : Fcolin Date : 14/11/02 Heure : 15:45 Archivé dans $/Bus/Ivy Commentaire: (vss 17) --- Ivy/ThreadedSocket.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 19670f7..31bcf18 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -138,7 +138,8 @@ void CThreadedSocket::Close() { if (m_hSocket != INVALID_SOCKET) { - ASSERT(SOCKET_ERROR != closesocket(m_hSocket)); + //ASSERT(SOCKET_ERROR != closesocket(m_hSocket)); + closesocket(m_hSocket); // close silently m_hSocket = INVALID_SOCKET; } @@ -419,8 +420,7 @@ UINT CThreadedSocket::SocketReader( ) TRACE( "CThreadedSocket::SocketReader( select error thread_id =( %d) )\n",reader_id); - if (m_hSocket != INVALID_SOCKET) - Close(); + Close(); h_reader = NULL; return sock_err; break; -- cgit v1.1 From e8934aef52d003b97a36a651ced63b7587d85eec Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:22 +0000 Subject: Utilisateur : Fcolin Date : 25/11/02 Heure : 16:15 Archivé dans $/Bus/Ivy Commentaire: (vss 18) --- Ivy/ThreadedSocket.cxx | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 31bcf18..42a8216 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -26,21 +26,8 @@ CThreadedSocket::CThreadedSocket() CThreadedSocket::~CThreadedSocket() { - long PreviousCount = 0; - int err; if (m_hSocket != INVALID_SOCKET) Close(); - //if ( thread ) // On fait de l'auto delete mais dans le cas de terminaison anormale l'object reste ????!!! - // delete thread; -// TRACE("CThreadedSocket waiting for thread end ...\n"); - if ( h_reader ) WaitForSingleObject( h_reader, INFINITE ); - // wake up writer - if ( h_writer ) - { - err = ReleaseSemaphore(send_count, 1, &PreviousCount); - WaitForSingleObject( h_writer, INFINITE ); - } -// TRACE("CThreadedSocket all thread ended\n"); } int CThreadedSocket::Create(UINT nSocketPort, int nSocketType, const char * lpszSocketAddress) { @@ -136,12 +123,24 @@ int CThreadedSocket::Bind(UINT nSocketPort, const char * lpszSocketAddress) void CThreadedSocket::Close() { + long PreviousCount = 0; + int err; if (m_hSocket != INVALID_SOCKET) { //ASSERT(SOCKET_ERROR != closesocket(m_hSocket)); closesocket(m_hSocket); // close silently m_hSocket = INVALID_SOCKET; - + //if ( thread ) // On fait de l'auto delete mais dans le cas de terminaison anormale l'object reste ????!!! + // delete thread; +// TRACE("CThreadedSocket waiting for thread end ...\n"); + if ( h_reader ) WaitForSingleObject( h_reader, INFINITE ); + // wake up writer + if ( h_writer ) + { + err = ReleaseSemaphore(send_count, 1, &PreviousCount); + WaitForSingleObject( h_writer, INFINITE ); + } +// TRACE("CThreadedSocket all thread ended\n"); } } int CThreadedSocket::Listen(int nConnectionBacklog) -- cgit v1.1 From 9700b7c0d1ec515e0ea59dfa5c7e42acd02815aa Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:24 +0000 Subject: Utilisateur : Fcolin Date : 23/01/04 Heure : 16:30 Archivé dans $/Bus/Ivy Commentaire: (vss 19) --- Ivy/ThreadedSocket.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 42a8216..2f32a26 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -133,12 +133,12 @@ void CThreadedSocket::Close() //if ( thread ) // On fait de l'auto delete mais dans le cas de terminaison anormale l'object reste ????!!! // delete thread; // TRACE("CThreadedSocket waiting for thread end ...\n"); - if ( h_reader ) WaitForSingleObject( h_reader, INFINITE ); + if ( h_reader ) WaitForSingleObject( h_reader, 5000 ); // wake up writer if ( h_writer ) { err = ReleaseSemaphore(send_count, 1, &PreviousCount); - WaitForSingleObject( h_writer, INFINITE ); + WaitForSingleObject( h_writer, 5000 ); } // TRACE("CThreadedSocket all thread ended\n"); } @@ -456,7 +456,7 @@ UINT CThreadedSocket::SocketReader( ) if (m_hSocket != INVALID_SOCKET) Close(); h_reader = NULL; -// TRACE( "CThreadedSocket::SocketReader( END thread_id =( 0x%x) )\n",reader_id); + TRACE( "CThreadedSocket::SocketReader( END thread_id =( 0x%x) )\n",reader_id); return 0; } -- cgit v1.1 From 2fab956d8131fb79a0dce36b34733afc88fe23ca Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:26 +0000 Subject: Utilisateur : Fcolin Date : 9/02/04 Heure : 16:14 Archivé dans $/Bus/Ivy Commentaire: (vss 20) --- Ivy/ThreadedSocket.cxx | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 2f32a26..3934095 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -128,8 +128,11 @@ void CThreadedSocket::Close() if (m_hSocket != INVALID_SOCKET) { //ASSERT(SOCKET_ERROR != closesocket(m_hSocket)); - closesocket(m_hSocket); // close silently + SOCKET temp = m_hSocket; // Thread ACK m_hSocket = INVALID_SOCKET; + TRACE( "CThreadedSocket::Close (reader=0x%0x) (writer=0x%0x)%\n", reader_id, writer_id ); + closesocket(temp); // close silently + //if ( thread ) // On fait de l'auto delete mais dans le cas de terminaison anormale l'object reste ????!!! // delete thread; // TRACE("CThreadedSocket waiting for thread end ...\n"); @@ -417,9 +420,9 @@ UINT CThreadedSocket::SocketReader( ) break; case SOCKET_ERROR: - TRACE( "CThreadedSocket::SocketReader( select error thread_id =( %d) )\n",reader_id); - - Close(); + TRACE( "CThreadedSocket::SocketReader( select error thread_id =( 0x%x) )\n",reader_id); + if ( (sock_err != WSAENOTSOCK ) && ( m_hSocket != INVALID_SOCKET )) // could be Invalid if close when in select + Close(); h_reader = NULL; return sock_err; break; @@ -512,7 +515,8 @@ UINT CThreadedSocket::SocketWriter( ) break; case SOCKET_ERROR: TRACE( "CThreadedSocketException( select )\n"); - if (m_hSocket != INVALID_SOCKET) Close(); + if ( (sock_err != WSAENOTSOCK ) && ( m_hSocket != INVALID_SOCKET )) // could be Invalid if close when in select + Close(); h_reader = NULL; return sock_err; break; -- cgit v1.1 From bb6dabd8e1afc8dd2474183a97d7663f1154d687 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:28 +0000 Subject: Utilisateur : Fcolin Date : 1/06/05 Heure : 16:45 Archivé dans $/Bus/Ivy Commentaire: (vss 21) --- Ivy/ThreadedSocket.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 3934095..f85b84d 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -2,7 +2,7 @@ // ////////////////////////////////////////////////////////////////////// -#include "stdafx.h" +#include "IvyStdAfx.h" #include "ThreadedSocket.h" -- cgit v1.1 From 97bfd72ffebfef20dedceb78c06ed2aa0742ea7c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:30 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 22) --- Ivy/ThreadedSocket.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index f85b84d..98235af 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -46,7 +46,7 @@ int CThreadedSocket::Create(UINT nSocketPort, int nSocketType, const char * lpsz -void CThreadedSocket::GetPeerName(string & rPeerAddress, UINT& rPeerPort) +void CThreadedSocket::GetPeerName(ivy::string & rPeerAddress, UINT& rPeerPort) { SOCKADDR_IN sockAddr; memset(&sockAddr, 0, sizeof(sockAddr)); @@ -57,7 +57,7 @@ void CThreadedSocket::GetPeerName(string & rPeerAddress, UINT& rPeerPort) rPeerAddress = inet_ntoa(sockAddr.sin_addr); } -void CThreadedSocket::GetSockName(string & rSocketAddress, UINT& rSocketPort) +void CThreadedSocket::GetSockName(ivy::string & rSocketAddress, UINT& rSocketPort) { SOCKADDR_IN sockAddr; memset(&sockAddr, 0, sizeof(sockAddr)); @@ -219,7 +219,7 @@ int CThreadedSocket::Receive(void* lpBuf, int nBufLen, int nFlags) return lg; } -int CThreadedSocket::ReceiveFrom(void* lpBuf, int nBufLen, string & rSocketAddress, UINT& rSocketPort, int nFlags) +int CThreadedSocket::ReceiveFrom(void* lpBuf, int nBufLen, ivy::string & rSocketAddress, UINT& rSocketPort, int nFlags) { SOCKADDR_IN sockAddr; -- cgit v1.1 From fba86770a42e8aae5c76fe63136ad648978b53bd Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:32 +0000 Subject: Utilisateur : Fcolin Date : 23/09/05 Heure : 15:27 Archivé dans $/Bus/Ivy Commentaire: (vss 23) --- Ivy/ThreadedSocket.cxx | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 98235af..5654758 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -71,7 +71,7 @@ void CThreadedSocket::GetSockName(ivy::string & rSocketAddress, UINT& rSocketPor ///////////////////////////////////////////////////////////////////////////// // CAscynSocket Operations -int CThreadedSocket::Accept(CThreadedSocket& rConnectedSocket, +SOCKET CThreadedSocket::Accept(CThreadedSocket& rConnectedSocket, SOCKADDR* lpSockAddr, int* lpSockAddrLen) { ASSERT(rConnectedSocket.m_hSocket == INVALID_SOCKET); @@ -213,32 +213,32 @@ int CThreadedSocket::Connect(const char * lpszHostAddress, UINT nHostPort) return Connect((SOCKADDR*)&sockAddr, sizeof(sockAddr)); } -int CThreadedSocket::Receive(void* lpBuf, int nBufLen, int nFlags) +size_t CThreadedSocket::Receive(void* lpBuf, size_t nBufLen, int nFlags) { - int lg = recv(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags); + int lg = recv(m_hSocket, (LPSTR)lpBuf, (int)nBufLen, nFlags); return lg; } -int CThreadedSocket::ReceiveFrom(void* lpBuf, int nBufLen, ivy::string & rSocketAddress, UINT& rSocketPort, int nFlags) +size_t CThreadedSocket::ReceiveFrom(void* lpBuf, size_t nBufLen, ivy::string & rSocketAddress, UINT& rSocketPort, int nFlags) { SOCKADDR_IN sockAddr; memset(&sockAddr, 0, sizeof(sockAddr)); - int nSockAddrLen = sizeof(sockAddr); - int nResult = ReceiveFrom(lpBuf, nBufLen, (SOCKADDR*)&sockAddr, &nSockAddrLen, nFlags); + size_t nSockAddrLen = sizeof(sockAddr); + size_t nResult = ReceiveFrom(lpBuf, nBufLen, (SOCKADDR*)&sockAddr, &nSockAddrLen, nFlags); rSocketPort = ntohs(sockAddr.sin_port); rSocketAddress = inet_ntoa(sockAddr.sin_addr); return nResult; } -int CThreadedSocket::Send(const void* lpBuf, int nBufLen, int nFlags) +size_t CThreadedSocket::Send(const void* lpBuf, size_t nBufLen, int nFlags) { - return send(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags); + return send(m_hSocket, (LPSTR)lpBuf, (int)nBufLen, nFlags); } -int CThreadedSocket::SendTo(const void* lpBuf, int nBufLen, UINT nHostPort, const char * lpszHostAddress, int nFlags) +size_t CThreadedSocket::SendTo(const void* lpBuf, size_t nBufLen, UINT nHostPort, const char * lpszHostAddress, int nFlags) { SOCKADDR_IN sockAddr; @@ -332,7 +332,7 @@ void CThreadedSocket::OnClose(int /*nErrorCode*/) // CThreadedSocket Implementation -int CThreadedSocket::Socket(int nSocketType, int nProtocolType, int nAddressFormat) +SOCKET CThreadedSocket::Socket(int nSocketType, int nProtocolType, int nAddressFormat) { ASSERT(m_hSocket == INVALID_SOCKET); -- cgit v1.1 From bc919bfe58f3dd881182082570f1c2424612734d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:34 +0000 Subject: Utilisateur : Fcolin Date : 16/11/05 Heure : 9:54 Archivé dans $/Bus/Ivy Commentaire: 64 bits ports (vss 24) --- Ivy/ThreadedSocket.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 5654758..610f9b7 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -130,7 +130,7 @@ void CThreadedSocket::Close() //ASSERT(SOCKET_ERROR != closesocket(m_hSocket)); SOCKET temp = m_hSocket; // Thread ACK m_hSocket = INVALID_SOCKET; - TRACE( "CThreadedSocket::Close (reader=0x%0x) (writer=0x%0x)%\n", reader_id, writer_id ); + TRACE( "CThreadedSocket::Close (reader=0x%0lx) (writer=0x%0lx)\n", reader_id, writer_id ); closesocket(temp); // close silently //if ( thread ) // On fait de l'auto delete mais dans le cas de terminaison anormale l'object reste ????!!! -- cgit v1.1 From 79e97e573fc073eb9554ca0b89e2d0580e89a286 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:36 +0000 Subject: Utilisateur : Fcolin Date : 18/11/05 Heure : 11:46 Archivé dans $/Bus/Ivy Commentaire: repassage a la STL et correction bug multithread (vss 25) --- Ivy/ThreadedSocket.cxx | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.cxx b/Ivy/ThreadedSocket.cxx index 610f9b7..ee1e03b 100644 --- a/Ivy/ThreadedSocket.cxx +++ b/Ivy/ThreadedSocket.cxx @@ -16,9 +16,11 @@ CThreadedSocket::CThreadedSocket() { - m_hSocket = INVALID_SOCKET; + m_hSocket = INVALID_SOCKET; h_reader = NULL; h_writer = NULL; + reader_id = 0; + writer_id = 0; listen_mode = false; connect_pending = true; send_pending = false; @@ -125,8 +127,13 @@ void CThreadedSocket::Close() { long PreviousCount = 0; int err; + DWORD currentThreadId; + + if (m_hSocket != INVALID_SOCKET) { + currentThreadId = GetCurrentThreadId(); + //ASSERT(SOCKET_ERROR != closesocket(m_hSocket)); SOCKET temp = m_hSocket; // Thread ACK m_hSocket = INVALID_SOCKET; @@ -136,9 +143,10 @@ void CThreadedSocket::Close() //if ( thread ) // On fait de l'auto delete mais dans le cas de terminaison anormale l'object reste ????!!! // delete thread; // TRACE("CThreadedSocket waiting for thread end ...\n"); - if ( h_reader ) WaitForSingleObject( h_reader, 5000 ); + if ( h_reader && currentThreadId != reader_id ) + WaitForSingleObject( h_reader, 5000 ); // wake up writer - if ( h_writer ) + if ( h_writer && currentThreadId != writer_id ) { err = ReleaseSemaphore(send_count, 1, &PreviousCount); WaitForSingleObject( h_writer, 5000 ); @@ -533,7 +541,7 @@ UINT CThreadedSocket::SocketWriter( ) } Close(); h_writer = NULL; -// TRACE( "CThreadedSocket::SocketWriter( END thread_id =( 0x%x) )\n",writer_id); + TRACE( "CThreadedSocket::SocketWriter( END thread_id =( 0x%x) )\n",writer_id); return 0; } -- cgit v1.1 From 852eab4605ad0d832c38b5ee69bf49c5417821c0 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:39 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:14 Créé (vss 1) --- Ivy/ThreadedSocket.h | 169 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 169 insertions(+) create mode 100644 Ivy/ThreadedSocket.h (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.h b/Ivy/ThreadedSocket.h new file mode 100644 index 0000000..19fca4f --- /dev/null +++ b/Ivy/ThreadedSocket.h @@ -0,0 +1,169 @@ +// ThreadedSocket.h: interface for the CThreadedSocket class. +// +////////////////////////////////////////////////////////////////////// + +#if !defined(AFX_THREADEDSOCKET_H__DC45EFD8_343F_11D3_8A15_00A0245B298A__INCLUDED_) +#define AFX_THREADEDSOCKET_H__DC45EFD8_343F_11D3_8A15_00A0245B298A__INCLUDED_ + +#if _MSC_VER > 1000 +#pragma once +#endif // _MSC_VER > 1000 + +#include + +class CThreadedSocketException //: public CException +{ +// DECLARE_DYNAMIC(CThreadedSocketException) +public: +// Constructor + CThreadedSocketException(char* pchMessage); + +public: + ~CThreadedSocketException() {} + virtual bool GetErrorMessage(string& lpstrError, unsigned int nMaxError, + unsigned int * pnHelpContext = 0); + int GetError() { return m_nError; }; +private: + int m_nError; + char * m_strMessage; +}; + +class CThreadedSocket //: public CObject +{ +// DECLARE_DYNAMIC(CThreadedSocket); +// typedef unsigned int SOCKET; +// typedef struct sockaddr SOCKADDR; + +public: + CThreadedSocket(); + virtual ~CThreadedSocket(); +// Construction +public: + void Create(unsigned int nSocketPort = 0, int nSocketType=SOCK_STREAM, + long lEvent = FD_READ | FD_WRITE | FD_OOB | FD_ACCEPT | FD_CONNECT | FD_CLOSE, + const char * lpszSocketAddress = 0); + +// Attributes +public: + SOCKET m_hSocket; + + operator SOCKET() const; + + void GetPeerName(string & rPeerAddress, unsigned int& rPeerPort); + + void GetSockName(string & rSocketAddress, unsigned int& rSocketPort); + +// Operations +public: + void Socket(int nSocketType=SOCK_STREAM, long lEvent = + FD_READ | FD_WRITE | FD_OOB | FD_ACCEPT | FD_CONNECT | FD_CLOSE, + int nProtocolType = 0, int nAddressFormat = PF_INET); + virtual void Accept(CThreadedSocket& rConnectedSocket, + SOCKADDR* lpSockAddr = NULL, int* lpSockAddrLen = NULL); + + void Bind(unsigned int nSocketPort, const char * lpszSocketAddress = 0); + + virtual void Close(); + + bool Connect(const char * lpszHostAddress, unsigned int nHostPort); + bool Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen); + + virtual int Receive(void* lpBuf, int nBufLen, int nFlags = 0); + + int ReceiveFrom(void* lpBuf, int nBufLen, + string & rSocketAddress, unsigned int & rSocketPort, int nFlags = 0); + + enum { receives = 0, sends = 1, both = 2 }; + + virtual void Send(const void* lpBuf, int nBufLen, int nFlags = 0); + + void SendTo(const void* lpBuf, int nBufLen, + unsigned int nHostPort, const char * lpszHostAddress = 0, int nFlags = 0); + void AsyncSelect(long lEvent = + FD_READ | FD_WRITE | FD_OOB | FD_ACCEPT | FD_CONNECT | FD_CLOSE); + + +inline CThreadedSocket::operator SOCKET() const + { return m_hSocket; } +inline void GetPeerName(SOCKADDR* lpSockAddr, int* lpSockAddrLen) + { + if ( getpeername(m_hSocket, lpSockAddr, lpSockAddrLen) == SOCKET_ERROR) + throw( new CThreadedSocketException( "getpeername" ) ); + } +inline void GetSockName(SOCKADDR* lpSockAddr, int* lpSockAddrLen) + { if ( getsockname(m_hSocket, lpSockAddr, lpSockAddrLen)== SOCKET_ERROR) + throw( new CThreadedSocketException( "getsockname" ) ); + } +inline void SetSockOpt(int nOptionName, const void* lpOptionValue, int nOptionLen, int nLevel = SOL_SOCKET) + { + if ( setsockopt(m_hSocket, nLevel, nOptionName, (LPCSTR)lpOptionValue, nOptionLen)== SOCKET_ERROR) + throw( new CThreadedSocketException( "setsockopt" ) ); + } +inline void GetSockOpt(int nOptionName, void* lpOptionValue, int* lpOptionLen, int nLevel = SOL_SOCKET) + { + if ( getsockopt(m_hSocket, nLevel, nOptionName, (LPSTR)lpOptionValue, lpOptionLen)== SOCKET_ERROR) + throw( new CThreadedSocketException( "getsockopt" ) ); + } + +static inline int CThreadedSocket::GetLastError() + { return WSAGetLastError(); } +inline void Bind(const SOCKADDR* lpSockAddr, int nSockAddrLen) + { + if ( bind(m_hSocket, lpSockAddr, nSockAddrLen)== SOCKET_ERROR ) + throw( new CThreadedSocketException( "bind" )); + } + +inline void IOCtl(long lCommand, unsigned long* lpArgument) + { if ( ioctlsocket(m_hSocket, lCommand, lpArgument)== SOCKET_ERROR) + throw( new CThreadedSocketException( "bind" ) ); + } +inline void Listen(int nConnectionBacklog=5) + { + if ( listen(m_hSocket, nConnectionBacklog)== SOCKET_ERROR) + throw( new CThreadedSocketException( "listen" ) ); + } +inline int ReceiveFrom(void* lpBuf, int nBufLen, SOCKADDR* lpSockAddr, int* lpSockAddrLen, int nFlags = 0) + { + int lg = recvfrom(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags, lpSockAddr, lpSockAddrLen); + if ( lg == SOCKET_ERROR ) + throw( new CThreadedSocketException( "recvfrom" ) ); + return lg; + } +inline bool ShutDown(int nHow = sends) + { + if ( shutdown(m_hSocket,nHow) == SOCKET_ERROR ) + throw( new CThreadedSocketException( "shutdown" ) ); + } +inline void SendTo(const void* lpBuf, int nBufLen, const SOCKADDR* lpSockAddr, int nSockAddrLen, int nFlags = 0) + { + if ( sendto(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags, lpSockAddr, nSockAddrLen)== SOCKET_ERROR ) + throw( new CThreadedSocketException( "sendto" ) ); + } + + + +// Overridable callbacks +protected: + virtual void OnWakeup(); + virtual void OnReceive(int nErrorCode); + virtual void OnSend(int nErrorCode); + virtual void OnOutOfBandData(int nErrorCode); + virtual void OnAccept(int nErrorCode); + virtual void OnConnect(int nErrorCode); + virtual void OnClose(int nErrorCode); +// Implementation + void StartListener(long lEvent); + long m_EventMask; + unsigned long thread_id; + HANDLE h_thread; + WSAEVENT m_hEvent[2]; // socket event for receive and send actions + unsigned int SocketThread(); //Client Thread + +// wrapper for thread routine +static DWORD WINAPI SocketThreadProc( void * pParam ); +static void Init(); +static bool Initialized; + +}; + +#endif // !defined(AFX_THREADEDSOCKET_H__DC45EFD8_343F_11D3_8A15_00A0245B298A__INCLUDED_) -- cgit v1.1 From 4b8a6b79df9e4433fff614c786441b75f52bcddc Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:40 +0000 Subject: Utilisateur : Fcolin Date : 16/06/00 Heure : 10:40 Archivé dans $/Ivy Commentaire: Init dll socket dans DLLMain (vss 2) --- Ivy/ThreadedSocket.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.h b/Ivy/ThreadedSocket.h index 19fca4f..1a3f405 100644 --- a/Ivy/ThreadedSocket.h +++ b/Ivy/ThreadedSocket.h @@ -161,8 +161,6 @@ protected: // wrapper for thread routine static DWORD WINAPI SocketThreadProc( void * pParam ); -static void Init(); -static bool Initialized; }; -- cgit v1.1 From 99d788dbb3bad0d82be026054d88f9245b0c5bcf Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:42 +0000 Subject: Utilisateur : Fcolin Date : 29/06/00 Heure : 15:59 Archivé dans $/Ivy Commentaire: Version multicast (vss 3) --- Ivy/ThreadedSocket.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.h b/Ivy/ThreadedSocket.h index 1a3f405..2fbe8c8 100644 --- a/Ivy/ThreadedSocket.h +++ b/Ivy/ThreadedSocket.h @@ -58,6 +58,9 @@ public: void Socket(int nSocketType=SOCK_STREAM, long lEvent = FD_READ | FD_WRITE | FD_OOB | FD_ACCEPT | FD_CONNECT | FD_CLOSE, int nProtocolType = 0, int nAddressFormat = PF_INET); + + void AddMember( const char * lpszHostAddress ); + virtual void Accept(CThreadedSocket& rConnectedSocket, SOCKADDR* lpSockAddr = NULL, int* lpSockAddrLen = NULL); -- cgit v1.1 From 3ac6d4f575306385ad90fce0a22901afa301132e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:44 +0000 Subject: Utilisateur : Fcolin Date : 23/01/01 Heure : 13:12 Archivé dans $/Ivy Commentaire: remove 'using name space std;' (vss 4) --- Ivy/ThreadedSocket.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.h b/Ivy/ThreadedSocket.h index 2fbe8c8..bcdf8e5 100644 --- a/Ivy/ThreadedSocket.h +++ b/Ivy/ThreadedSocket.h @@ -20,7 +20,7 @@ public: public: ~CThreadedSocketException() {} - virtual bool GetErrorMessage(string& lpstrError, unsigned int nMaxError, + virtual bool GetErrorMessage(String& lpstrError, unsigned int nMaxError, unsigned int * pnHelpContext = 0); int GetError() { return m_nError; }; private: @@ -49,9 +49,9 @@ public: operator SOCKET() const; - void GetPeerName(string & rPeerAddress, unsigned int& rPeerPort); + void GetPeerName(String & rPeerAddress, unsigned int& rPeerPort); - void GetSockName(string & rSocketAddress, unsigned int& rSocketPort); + void GetSockName(String & rSocketAddress, unsigned int& rSocketPort); // Operations public: @@ -74,7 +74,7 @@ public: virtual int Receive(void* lpBuf, int nBufLen, int nFlags = 0); int ReceiveFrom(void* lpBuf, int nBufLen, - string & rSocketAddress, unsigned int & rSocketPort, int nFlags = 0); + String & rSocketAddress, unsigned int & rSocketPort, int nFlags = 0); enum { receives = 0, sends = 1, both = 2 }; -- cgit v1.1 From 1216a6d96c4aa7e76f6999ea39d49d3f444674ac Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:46 +0000 Subject: Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 5) --- Ivy/ThreadedSocket.h | 27 ++++++++------------------- 1 file changed, 8 insertions(+), 19 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.h b/Ivy/ThreadedSocket.h index bcdf8e5..829c562 100644 --- a/Ivy/ThreadedSocket.h +++ b/Ivy/ThreadedSocket.h @@ -2,25 +2,19 @@ // ////////////////////////////////////////////////////////////////////// -#if !defined(AFX_THREADEDSOCKET_H__DC45EFD8_343F_11D3_8A15_00A0245B298A__INCLUDED_) -#define AFX_THREADEDSOCKET_H__DC45EFD8_343F_11D3_8A15_00A0245B298A__INCLUDED_ -#if _MSC_VER > 1000 #pragma once -#endif // _MSC_VER > 1000 -#include - -class CThreadedSocketException //: public CException +class CThreadedSocketException { -// DECLARE_DYNAMIC(CThreadedSocketException) + public: // Constructor CThreadedSocketException(char* pchMessage); public: ~CThreadedSocketException() {} - virtual bool GetErrorMessage(String& lpstrError, unsigned int nMaxError, + virtual bool GetErrorMessage(string& lpstrError, unsigned int nMaxError, unsigned int * pnHelpContext = 0); int GetError() { return m_nError; }; private: @@ -28,11 +22,8 @@ private: char * m_strMessage; }; -class CThreadedSocket //: public CObject +class CThreadedSocket { -// DECLARE_DYNAMIC(CThreadedSocket); -// typedef unsigned int SOCKET; -// typedef struct sockaddr SOCKADDR; public: CThreadedSocket(); @@ -49,9 +40,9 @@ public: operator SOCKET() const; - void GetPeerName(String & rPeerAddress, unsigned int& rPeerPort); + void GetPeerName(string & rPeerAddress, unsigned int& rPeerPort); - void GetSockName(String & rSocketAddress, unsigned int& rSocketPort); + void GetSockName(string & rSocketAddress, unsigned int& rSocketPort); // Operations public: @@ -74,7 +65,7 @@ public: virtual int Receive(void* lpBuf, int nBufLen, int nFlags = 0); int ReceiveFrom(void* lpBuf, int nBufLen, - String & rSocketAddress, unsigned int & rSocketPort, int nFlags = 0); + string & rSocketAddress, unsigned int & rSocketPort, int nFlags = 0); enum { receives = 0, sends = 1, both = 2 }; @@ -91,7 +82,7 @@ inline CThreadedSocket::operator SOCKET() const inline void GetPeerName(SOCKADDR* lpSockAddr, int* lpSockAddrLen) { if ( getpeername(m_hSocket, lpSockAddr, lpSockAddrLen) == SOCKET_ERROR) - throw( new CThreadedSocketException( "getpeername" ) ); + throw ( new CThreadedSocketException( "getpeername" ) ); } inline void GetSockName(SOCKADDR* lpSockAddr, int* lpSockAddrLen) { if ( getsockname(m_hSocket, lpSockAddr, lpSockAddrLen)== SOCKET_ERROR) @@ -166,5 +157,3 @@ protected: static DWORD WINAPI SocketThreadProc( void * pParam ); }; - -#endif // !defined(AFX_THREADEDSOCKET_H__DC45EFD8_343F_11D3_8A15_00A0245B298A__INCLUDED_) -- cgit v1.1 From f65446ec7d815cd429f36c306de5905712ec89af Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:48 +0000 Subject: Utilisateur : Fcolin Date : 2/02/01 Heure : 18:30 Archivé dans $/Ivy Commentaire: win CE compile not finished (vss 6) --- Ivy/ThreadedSocket.h | 120 ++++++++++++++++++++++----------------------------- 1 file changed, 51 insertions(+), 69 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.h b/Ivy/ThreadedSocket.h index 829c562..ab8e3cd 100644 --- a/Ivy/ThreadedSocket.h +++ b/Ivy/ThreadedSocket.h @@ -5,22 +5,7 @@ #pragma once -class CThreadedSocketException -{ - -public: -// Constructor - CThreadedSocketException(char* pchMessage); -public: - ~CThreadedSocketException() {} - virtual bool GetErrorMessage(string& lpstrError, unsigned int nMaxError, - unsigned int * pnHelpContext = 0); - int GetError() { return m_nError; }; -private: - int m_nError; - char * m_strMessage; -}; class CThreadedSocket { @@ -30,9 +15,7 @@ public: virtual ~CThreadedSocket(); // Construction public: - void Create(unsigned int nSocketPort = 0, int nSocketType=SOCK_STREAM, - long lEvent = FD_READ | FD_WRITE | FD_OOB | FD_ACCEPT | FD_CONNECT | FD_CLOSE, - const char * lpszSocketAddress = 0); + int Create(unsigned int nSocketPort = 0, int nSocketType=SOCK_STREAM, const char * lpszSocketAddress = 0); // Attributes public: @@ -46,21 +29,19 @@ public: // Operations public: - void Socket(int nSocketType=SOCK_STREAM, long lEvent = - FD_READ | FD_WRITE | FD_OOB | FD_ACCEPT | FD_CONNECT | FD_CLOSE, - int nProtocolType = 0, int nAddressFormat = PF_INET); + int Socket(int nSocketType=SOCK_STREAM, int nProtocolType = 0, int nAddressFormat = PF_INET); - void AddMember( const char * lpszHostAddress ); + int AddMember( const char * lpszHostAddress ); - virtual void Accept(CThreadedSocket& rConnectedSocket, + virtual int Accept(CThreadedSocket& rConnectedSocket, SOCKADDR* lpSockAddr = NULL, int* lpSockAddrLen = NULL); - void Bind(unsigned int nSocketPort, const char * lpszSocketAddress = 0); + int Bind(unsigned int nSocketPort, const char * lpszSocketAddress = 0); virtual void Close(); - bool Connect(const char * lpszHostAddress, unsigned int nHostPort); - bool Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen); + int Connect(const char * lpszHostAddress, unsigned int nHostPort); + int Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen); virtual int Receive(void* lpBuf, int nBufLen, int nFlags = 0); @@ -69,76 +50,67 @@ public: enum { receives = 0, sends = 1, both = 2 }; - virtual void Send(const void* lpBuf, int nBufLen, int nFlags = 0); + virtual int Send(const void* lpBuf, int nBufLen, int nFlags = 0); - void SendTo(const void* lpBuf, int nBufLen, + int SendTo(const void* lpBuf, int nBufLen, unsigned int nHostPort, const char * lpszHostAddress = 0, int nFlags = 0); - void AsyncSelect(long lEvent = - FD_READ | FD_WRITE | FD_OOB | FD_ACCEPT | FD_CONNECT | FD_CLOSE); + inline CThreadedSocket::operator SOCKET() const { return m_hSocket; } -inline void GetPeerName(SOCKADDR* lpSockAddr, int* lpSockAddrLen) +inline int GetPeerName(SOCKADDR* lpSockAddr, int* lpSockAddrLen) { - if ( getpeername(m_hSocket, lpSockAddr, lpSockAddrLen) == SOCKET_ERROR) - throw ( new CThreadedSocketException( "getpeername" ) ); + return getpeername(m_hSocket, lpSockAddr, lpSockAddrLen); } -inline void GetSockName(SOCKADDR* lpSockAddr, int* lpSockAddrLen) - { if ( getsockname(m_hSocket, lpSockAddr, lpSockAddrLen)== SOCKET_ERROR) - throw( new CThreadedSocketException( "getsockname" ) ); +inline int GetSockName(SOCKADDR* lpSockAddr, int* lpSockAddrLen) + { + return getsockname(m_hSocket, lpSockAddr, lpSockAddrLen); } -inline void SetSockOpt(int nOptionName, const void* lpOptionValue, int nOptionLen, int nLevel = SOL_SOCKET) +inline int SetSockOpt(int nOptionName, const void* lpOptionValue, int nOptionLen, int nLevel = SOL_SOCKET) { - if ( setsockopt(m_hSocket, nLevel, nOptionName, (LPCSTR)lpOptionValue, nOptionLen)== SOCKET_ERROR) - throw( new CThreadedSocketException( "setsockopt" ) ); + return setsockopt(m_hSocket, nLevel, nOptionName, (LPCSTR)lpOptionValue, nOptionLen); } -inline void GetSockOpt(int nOptionName, void* lpOptionValue, int* lpOptionLen, int nLevel = SOL_SOCKET) +inline int GetSockOpt(int nOptionName, void* lpOptionValue, int* lpOptionLen, int nLevel = SOL_SOCKET) { - if ( getsockopt(m_hSocket, nLevel, nOptionName, (LPSTR)lpOptionValue, lpOptionLen)== SOCKET_ERROR) - throw( new CThreadedSocketException( "getsockopt" ) ); + return getsockopt(m_hSocket, nLevel, nOptionName, (LPSTR)lpOptionValue, lpOptionLen); } static inline int CThreadedSocket::GetLastError() - { return WSAGetLastError(); } -inline void Bind(const SOCKADDR* lpSockAddr, int nSockAddrLen) + { return ::WSAGetLastError(); } +inline int Bind(const SOCKADDR* lpSockAddr, int nSockAddrLen) { - if ( bind(m_hSocket, lpSockAddr, nSockAddrLen)== SOCKET_ERROR ) - throw( new CThreadedSocketException( "bind" )); + return bind(m_hSocket, lpSockAddr, nSockAddrLen); } -inline void IOCtl(long lCommand, unsigned long* lpArgument) - { if ( ioctlsocket(m_hSocket, lCommand, lpArgument)== SOCKET_ERROR) - throw( new CThreadedSocketException( "bind" ) ); +inline int IOCtl(long lCommand, unsigned long* lpArgument) + { + return ioctlsocket(m_hSocket, lCommand, lpArgument); } -inline void Listen(int nConnectionBacklog=5) +inline int Listen(int nConnectionBacklog=5) { - if ( listen(m_hSocket, nConnectionBacklog)== SOCKET_ERROR) - throw( new CThreadedSocketException( "listen" ) ); + int err = listen(m_hSocket, nConnectionBacklog); + if ( !err ) + listen_mode = true; + return err; } inline int ReceiveFrom(void* lpBuf, int nBufLen, SOCKADDR* lpSockAddr, int* lpSockAddrLen, int nFlags = 0) { int lg = recvfrom(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags, lpSockAddr, lpSockAddrLen); - if ( lg == SOCKET_ERROR ) - throw( new CThreadedSocketException( "recvfrom" ) ); return lg; } -inline bool ShutDown(int nHow = sends) +inline int ShutDown(int nHow = sends) { - if ( shutdown(m_hSocket,nHow) == SOCKET_ERROR ) - throw( new CThreadedSocketException( "shutdown" ) ); + return shutdown(m_hSocket,nHow); } -inline void SendTo(const void* lpBuf, int nBufLen, const SOCKADDR* lpSockAddr, int nSockAddrLen, int nFlags = 0) +inline int SendTo(const void* lpBuf, int nBufLen, const SOCKADDR* lpSockAddr, int nSockAddrLen, int nFlags = 0) { - if ( sendto(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags, lpSockAddr, nSockAddrLen)== SOCKET_ERROR ) - throw( new CThreadedSocketException( "sendto" ) ); + return sendto(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags, lpSockAddr, nSockAddrLen); } - // Overridable callbacks protected: - virtual void OnWakeup(); virtual void OnReceive(int nErrorCode); virtual void OnSend(int nErrorCode); virtual void OnOutOfBandData(int nErrorCode); @@ -146,14 +118,24 @@ protected: virtual void OnConnect(int nErrorCode); virtual void OnClose(int nErrorCode); // Implementation - void StartListener(long lEvent); - long m_EventMask; - unsigned long thread_id; - HANDLE h_thread; - WSAEVENT m_hEvent[2]; // socket event for receive and send actions - unsigned int SocketThread(); //Client Thread + int StartListener(); + int StartWriter(); + bool SignalWriter(); + + HANDLE h_reader; + HANDLE h_writer; + unsigned long reader_id; + unsigned long writer_id; + unsigned int SocketReader(); //Receiver Thread + unsigned int SocketWriter(); //Sender Thread + bool listen_mode; + bool connect_pending; + bool send_pending; + HANDLE send_count; + // wrapper for thread routine -static DWORD WINAPI SocketThreadProc( void * pParam ); +static DWORD WINAPI SocketReaderProc( void * pParam ); +static DWORD WINAPI SocketWriterProc( void * pParam ); }; -- cgit v1.1 From 19ce23a32f459a91a76035f2fee5c859066fa5fa Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:50 +0000 Subject: Utilisateur : Fcolin Date : 14/09/01 Heure : 16:44 Archivé dans $/Ivy Commentaire: correction BUG Ivy socket Listen apres start Listener et regexp_in.resize (vss 7) --- Ivy/ThreadedSocket.h | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.h b/Ivy/ThreadedSocket.h index ab8e3cd..1827c52 100644 --- a/Ivy/ThreadedSocket.h +++ b/Ivy/ThreadedSocket.h @@ -42,6 +42,7 @@ public: int Connect(const char * lpszHostAddress, unsigned int nHostPort); int Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen); + int Listen(int nConnectionBacklog=5); virtual int Receive(void* lpBuf, int nBufLen, int nFlags = 0); @@ -87,13 +88,7 @@ inline int IOCtl(long lCommand, unsigned long* lpArgument) { return ioctlsocket(m_hSocket, lCommand, lpArgument); } -inline int Listen(int nConnectionBacklog=5) - { - int err = listen(m_hSocket, nConnectionBacklog); - if ( !err ) - listen_mode = true; - return err; - } + inline int ReceiveFrom(void* lpBuf, int nBufLen, SOCKADDR* lpSockAddr, int* lpSockAddrLen, int nFlags = 0) { int lg = recvfrom(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags, lpSockAddr, lpSockAddrLen); -- cgit v1.1 From fe6c1ec690a82deddc9fa0c5ff9eb5dde9c83c8c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:52 +0000 Subject: Utilisateur : Fcolin Date : 25/10/01 Heure : 18:39 Archivé dans $/Ivy (vss 8) --- Ivy/ThreadedSocket.h | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.h b/Ivy/ThreadedSocket.h index 1827c52..9771f10 100644 --- a/Ivy/ThreadedSocket.h +++ b/Ivy/ThreadedSocket.h @@ -21,7 +21,7 @@ public: public: SOCKET m_hSocket; - operator SOCKET() const; + inline operator SOCKET() const { return m_hSocket; }; void GetPeerName(string & rPeerAddress, unsigned int& rPeerPort); @@ -57,9 +57,6 @@ public: unsigned int nHostPort, const char * lpszHostAddress = 0, int nFlags = 0); - -inline CThreadedSocket::operator SOCKET() const - { return m_hSocket; } inline int GetPeerName(SOCKADDR* lpSockAddr, int* lpSockAddrLen) { return getpeername(m_hSocket, lpSockAddr, lpSockAddrLen); -- cgit v1.1 From bfcb17aa05cda240abeb0fffc41bb112b04e00eb Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:54 +0000 Subject: Utilisateur : Fcolin Date : 2/06/05 Heure : 18:42 Archivé dans $/Bus/Ivy Commentaire: Suppression de la STL et ajout d'un namespace pour les datatypes internes Ivy (vss 9) --- Ivy/ThreadedSocket.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.h b/Ivy/ThreadedSocket.h index 9771f10..85262cd 100644 --- a/Ivy/ThreadedSocket.h +++ b/Ivy/ThreadedSocket.h @@ -23,9 +23,9 @@ public: inline operator SOCKET() const { return m_hSocket; }; - void GetPeerName(string & rPeerAddress, unsigned int& rPeerPort); + void GetPeerName(ivy::string & rPeerAddress, unsigned int& rPeerPort); - void GetSockName(string & rSocketAddress, unsigned int& rSocketPort); + void GetSockName(ivy::string & rSocketAddress, unsigned int& rSocketPort); // Operations public: @@ -47,7 +47,7 @@ public: virtual int Receive(void* lpBuf, int nBufLen, int nFlags = 0); int ReceiveFrom(void* lpBuf, int nBufLen, - string & rSocketAddress, unsigned int & rSocketPort, int nFlags = 0); + ivy::string & rSocketAddress, unsigned int & rSocketPort, int nFlags = 0); enum { receives = 0, sends = 1, both = 2 }; -- cgit v1.1 From d335c71e7c5c30293d82d8336494cb629e2d610e Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:56 +0000 Subject: Utilisateur : Fcolin Date : 23/09/05 Heure : 15:27 Archivé dans $/Bus/Ivy Commentaire: (vss 10) --- Ivy/ThreadedSocket.h | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) (limited to 'Ivy') diff --git a/Ivy/ThreadedSocket.h b/Ivy/ThreadedSocket.h index 85262cd..ad33c3e 100644 --- a/Ivy/ThreadedSocket.h +++ b/Ivy/ThreadedSocket.h @@ -29,11 +29,11 @@ public: // Operations public: - int Socket(int nSocketType=SOCK_STREAM, int nProtocolType = 0, int nAddressFormat = PF_INET); + SOCKET Socket(int nSocketType=SOCK_STREAM, int nProtocolType = 0, int nAddressFormat = PF_INET); int AddMember( const char * lpszHostAddress ); - virtual int Accept(CThreadedSocket& rConnectedSocket, + virtual SOCKET Accept(CThreadedSocket& rConnectedSocket, SOCKADDR* lpSockAddr = NULL, int* lpSockAddrLen = NULL); int Bind(unsigned int nSocketPort, const char * lpszSocketAddress = 0); @@ -44,16 +44,16 @@ public: int Connect(const SOCKADDR* lpSockAddr, int nSockAddrLen); int Listen(int nConnectionBacklog=5); - virtual int Receive(void* lpBuf, int nBufLen, int nFlags = 0); + virtual size_t Receive(void* lpBuf, size_t nBufLen, int nFlags = 0); - int ReceiveFrom(void* lpBuf, int nBufLen, + size_t ReceiveFrom(void* lpBuf, size_t nBufLen, ivy::string & rSocketAddress, unsigned int & rSocketPort, int nFlags = 0); enum { receives = 0, sends = 1, both = 2 }; - virtual int Send(const void* lpBuf, int nBufLen, int nFlags = 0); + virtual size_t Send(const void* lpBuf, size_t nBufLen, int nFlags = 0); - int SendTo(const void* lpBuf, int nBufLen, + size_t SendTo(const void* lpBuf, size_t nBufLen, unsigned int nHostPort, const char * lpszHostAddress = 0, int nFlags = 0); @@ -86,18 +86,20 @@ inline int IOCtl(long lCommand, unsigned long* lpArgument) return ioctlsocket(m_hSocket, lCommand, lpArgument); } -inline int ReceiveFrom(void* lpBuf, int nBufLen, SOCKADDR* lpSockAddr, int* lpSockAddrLen, int nFlags = 0) +inline size_t ReceiveFrom(void* lpBuf, size_t nBufLen, SOCKADDR* lpSockAddr, size_t* lpSockAddrLen, int nFlags = 0) { - int lg = recvfrom(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags, lpSockAddr, lpSockAddrLen); + int len = (int)*lpSockAddrLen; // Non conforme a Unix + size_t lg = recvfrom(m_hSocket, (LPSTR)lpBuf, (int)nBufLen, nFlags, lpSockAddr, &len); + *lpSockAddrLen = len; return lg; } inline int ShutDown(int nHow = sends) { return shutdown(m_hSocket,nHow); } -inline int SendTo(const void* lpBuf, int nBufLen, const SOCKADDR* lpSockAddr, int nSockAddrLen, int nFlags = 0) +inline size_t SendTo(const void* lpBuf, size_t nBufLen, const SOCKADDR* lpSockAddr, size_t nSockAddrLen, int nFlags = 0) { - return sendto(m_hSocket, (LPSTR)lpBuf, nBufLen, nFlags, lpSockAddr, nSockAddrLen); + return sendto(m_hSocket, (LPSTR)lpBuf, (int)nBufLen, nFlags, lpSockAddr, (int)nSockAddrLen); } -- cgit v1.1 From 1c6403ed8668cac26362e786567d7a68b73bb0ef Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:05:59 +0000 Subject: Utilisateur : Fcolin Date : 22/09/06 Heure : 14:54 Créé Commentaire: (vss 1) --- Ivy/intervalRegexp.c | 432 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 432 insertions(+) create mode 100644 Ivy/intervalRegexp.c (limited to 'Ivy') diff --git a/Ivy/intervalRegexp.c b/Ivy/intervalRegexp.c new file mode 100644 index 0000000..6efcd72 --- /dev/null +++ b/Ivy/intervalRegexp.c @@ -0,0 +1,432 @@ +#include +#include +#include +#include +#include + +#include "intervalRegexp.h" + +#ifdef __PRETTY_FUNCTION__ +#else +#define __PRETTY_FUNCTION__ __FUNCTION__ +#endif + + +#define MAXINT( a , b ) ((a) > (b) ? (a) : (b)) +#define MININT( a , b ) ((a) < (b) ? (a) : (b)) + +#define Perr(...) (perr ( __PRETTY_FUNCTION__, __VA_ARGS__)) +#define CHECK_AND_RETURN(a) if (strlen (locBuf) <= buflen) { \ + strcpy (a, locBuf); \ + return success; \ + } else { \ + return Perr ("CHECK_AND_RETURN"); } + +#define EndLocBuf (&(locBuf[strlen(locBuf)])) +#ifdef WIN32 +#define snprintf _snprintf +#endif +#define AddLocBuf(...) snprintf (EndLocBuf, sizeof (locBuf)-strlen(locBuf), __VA_ARGS__) + +typedef struct { + int max; + int rank; +} NextMax ; + + +typedef char bool; + +const bool success = 1; +const bool fail = 0; + + +static bool strictPosRegexpGen (char *regexp, size_t buflen, long min, long max, const char* decimalPart, + const char* boundDecimalPart); +static bool genAtRank (char *regexp, size_t buflen, const char *min, const char *max, int rank); +static bool genPreRank (char *preRank, size_t buflen, const char *min, const char *max, int rank); +static bool genRank (char *outRank, size_t buflen, const char *min, const char *max, int rank); +static bool genPostRank (char *postRank, size_t buflen, int rank); +static bool substr (char *substring, size_t buflen, const char* expr, size_t pos, size_t len); +static char* reverse (char *string); +static char* longtoa (char *string, size_t buflen, long n); +static NextMax nextMax (const char *min, const char *max); +static bool perr (const char* func, const char *fmt, ...); + + + +/* +# __ _ _ __ _____ +# / _` | | '_ \ / ____| +# _ __ ___ | (_| | ___ __ __ | |_) | | | __ ___ _ __ +# | '__| / _ \ \__, | / _ \ \ \/ / | .__/ | | |_ | / _ \ | '_ \ +# | | | __/ __/ | | __/ > < | | | |__| | | __/ | | | | +# |_| \___| |___/ \___| /_/\_\ |_| \_____| \___| |_| |_| +*/ +int regexpGen (char *regexp, size_t buflen, long min, long max, int flottant) +{ + char *decimalPart = ""; + char *boundDecimalPart = ""; + char locBuf [8192] = "(?:"; + + + if (flottant) { + decimalPart = "(?:\\.\\d+)?"; + boundDecimalPart = "(?:\\.0+)?"; + } + + if (min > max) { + int nmin = max; + max = min; + min = nmin; + } + + if (min == max) { + AddLocBuf ("%ld%s", min, decimalPart); + } else if (min < 0) { + if (max < 0) { + // reg = '\-(?:' . strictPosRegexpGen (-max, -min, decimalPart, boundDecimalPart). ')'; + AddLocBuf ("\\-(?:"); + if (strictPosRegexpGen (EndLocBuf, sizeof (locBuf)-strlen(locBuf), -min, -max, decimalPart, + boundDecimalPart) == fail) return fail; + AddLocBuf (")"); + } else if (max == 0) { + AddLocBuf ("(?:0%s)|(?:-0%s)|-(?:", boundDecimalPart, decimalPart); + if (strictPosRegexpGen (EndLocBuf, sizeof (locBuf)-strlen(locBuf), 1, -min, decimalPart, + boundDecimalPart)== fail) return fail; + AddLocBuf (")"); + } else { + //reg ='(?:' . regexpGen (min, 0,withDecimal) . '|' . regexpGen (0, max, withDecimal). ')' ; + AddLocBuf ("(?:"); + if (regexpGen (EndLocBuf, sizeof (locBuf)-strlen(locBuf), min, 0, flottant)== fail) return fail; + AddLocBuf ("|"); + if (regexpGen (EndLocBuf, sizeof (locBuf)-strlen(locBuf), 0, max, flottant)== fail) return fail; + AddLocBuf (")"); + } + } else if (min == 0) { + // reg = "(?:0{decimalPart})|" . strictPosRegexpGen (1, max, decimalPart,boundDecimalPart) ; + AddLocBuf ("(?:0%s)|",decimalPart); + if (strictPosRegexpGen (EndLocBuf, sizeof (locBuf)-strlen(locBuf), 1, max, decimalPart, + boundDecimalPart)== fail) return fail; + } else { + if (strictPosRegexpGen (EndLocBuf, sizeof (locBuf)-strlen(locBuf), min, max, decimalPart, + boundDecimalPart)== fail) return fail; + } + + AddLocBuf (")(?![\\d.])"); + CHECK_AND_RETURN (regexp); +} + +/* +# _ _ _ _____ +# | | (_) | | | __ \ +# ___ | |_ _ __ _ ___ | |_ | |__) | ___ ___ +# / __| | __| | '__| | | / __| | __| | ___/ / _ \ / __| +# \__ \ \ |_ | | | | | (__ \ |_ | | | (_) | \__ \ +# |___/ \__| |_| |_| \___| \__| |_| \___/ |___/ +# _____ __ _ _ __ _____ +# | __ \ / _` | | '_ \ / ____| +# | |__) | ___ | (_| | ___ __ __ | |_) | | | __ ___ _ __ +# | _ / / _ \ \__, | / _ \ \ \/ / | .__/ | | |_ | / _ \ | '_ \ +# | | \ \ | __/ __/ | | __/ > < | | | |__| | | __/ | | | | +# |_| \_\ \___| |___/ \___| /_/\_\ |_| \_____| \___| |_| |_| +*/ +static bool strictPosRegexpGen (char *regexp, size_t buflen, long min, long max, const char* decimalPart, + const char* boundDecimalPart) +{ + +#define maxSubReg 64 +#define digitRegSize 128 + + char regList[maxSubReg][digitRegSize]; + char locBuf[maxSubReg*digitRegSize] ; + size_t regIndex=0,i; + size_t nbRank; + char maxAsString[32], minAsString[32]; + NextMax nMax; + + + if ((min <= 0) || (max <= 0)) return Perr ("min or max <= 0"); + if (min == max) { + sprintf (EndLocBuf, "%ld", max); + } else { + + max--; + + nbRank = strlen (longtoa (maxAsString, sizeof (maxAsString), max)); + do { + nMax = nextMax (longtoa (minAsString, sizeof (minAsString), min), + longtoa (maxAsString, sizeof (maxAsString), max)); + if (genAtRank (regList[regIndex++], digitRegSize, minAsString, + longtoa (maxAsString, sizeof (maxAsString), + nMax.max), nMax.rank) == fail) return fail; + if (regIndex == maxSubReg) return Perr ("regIndex == maxSubReg"); + min = nMax.max +1; + } while (nMax.max != max); + + locBuf[0] = 0; + for (i=0; i < \ |_ | | | | | (_| | > < +# |_| |_| \___| /_/\_\ \__| |_| |_| \__,_| /_/\_\ +*/ +static NextMax nextMax (const char *min, const char *max) +{ + NextMax nextMax ={0,0}; + char revMin[32], revMax[32]; + size_t nbDigitsMin, nbDigitsMax; + size_t rankRev=0, rankForw, rank=0; + int i; + int currMax; + + nbDigitsMin = strlen (min); + nbDigitsMax = strlen (max); + + for (i=nbDigitsMin-1; i >= 0; i--) { + revMin[nbDigitsMin-i-1]= min[i]; + // printf ("DBG> nextMax revMin[%d]= %c\n", nbDigitsMin-i-1, min[i]); + } + for (i=nbDigitsMax-nbDigitsMin; i >= 0; i--) { + revMin[nbDigitsMax-i]= '0'; + // printf ("DBG> nextMax revMin[%d]= %c\n", nbDigitsMax-i, '0'); + } + + for (i=nbDigitsMax-1; i >= 0; i--) { + revMax[nbDigitsMax-i-1]= max[i]; + } + revMin[nbDigitsMax] = revMax[nbDigitsMax] = 0; + rankForw = nbDigitsMax -1; + + // printf ("DBG> nextMax rev(%s)=%s rev(%s)=%s rankForw=%d\n", min, revMin, max, revMax, rankForw); + + // en partant des unitées (digit de poids faible), premier digit de min != 0 + while ((revMin[rankRev] == '0') && (rankRev < nbDigitsMax)) rankRev++; + // en partant du digit de poids fort, premier digit de max != du même digit de revMin + while ((revMin[rankForw] == revMax[rankForw]) && rankForw > 0) rankForw--; + + if (rankForw <= rankRev) { + rank = rankForw; + revMin[rankForw]= revMax[rankForw] - (rankForw ? 1 : 0); + for (i=0; i currMax) nextMax.max = currMax; + + // printf ("DBG> nextMax ('%s', '%s') = %d@%d\n", min, max, nextMax.max, nextMax.rank); + return (nextMax); +} + + +/* +# __ _ ____ _ +# / _` | / __ \ | | +# | (_| | ___ _ __ / / _` | _ __ __ _ _ __ | | _ +# \__, | / _ \ | '_ \ | | (_| | | '__| / _` | | '_ \ | |/ / +# __/ | | __/ | | | | \ \__,_| | | | (_| | | | | | | < +# |___/ \___| |_| |_| \____/ |_| \__,_| |_| |_| |_|\_\ +*/ +static bool genAtRank (char *regexp, size_t buflen, const char *min, const char *max, int rank) +{ + char locBuf [512]; + + if (genPreRank (locBuf, sizeof (locBuf), min, max, rank) == fail) return (fail); + if (genRank (EndLocBuf, sizeof (locBuf)-strlen(locBuf), min, max, rank) == fail) return (fail); + if (genPostRank (EndLocBuf, sizeof (locBuf)-strlen(locBuf), rank) == fail) return (fail); + + + CHECK_AND_RETURN (regexp); +} + +/* +# __ _ _____ _____ _ +# / _` | | __ \ | __ \ | | +# | (_| | ___ _ __ | |__) | _ __ ___ | |__) | __ _ _ __ | | _ +# \__, | / _ \ | '_ \ | ___/ | '__| / _ \ | _ / / _` | | '_ \ | |/ / +# __/ | | __/ | | | | | | | | | __/ | | \ \ | (_| | | | | | | < +# |___/ \___| |_| |_| |_| |_| \___| |_| \_\ \__,_| |_| |_| |_|\_\ +*/ +static bool genPreRank (char *preRank, size_t buflen, const char *min, const char *max, int rank) +{ + char locBuf [512], locBufMax[512]; + const char *lmin, *lmax; + int i=0, j=0; + + while (min[i] == '0') i++; + while (max[j] == '0') j++; + + lmin = &(min[i]); + lmax = &(max[j]); + + // printf ("DBG> genPreRank (lmin='%s'[%d], lmax='%s'[%d], rank=%d\n", lmin, (int) strlen (lmin), lmax, + // (int) strlen (lmax), rank); + + if (substr (locBuf, sizeof (locBuf), lmin, 0, strlen (lmin) - rank) == fail) return fail; + if (substr (locBufMax, sizeof (locBufMax), lmax, 0, strlen (lmax) - rank) == fail) return fail; + + if (strncmp (locBuf, locBufMax, MININT (sizeof (locBuf), sizeof (locBufMax))) != 0) + return Perr ("min=%s[%s] and max=%s[%s] should be invariants at rank %d", locBuf, min, locBufMax, max, rank); + + // printf ("DBG> genPreRank ('%s', '%s', %d) = '%s'\n", min, max, rank, locBuf); + + CHECK_AND_RETURN (preRank); +} + + +/* +# __ _ _____ _ +# / _` | | __ \ | | +# | (_| | ___ _ __ | |__) | __ _ _ __ | | _ +# \__, | / _ \ | '_ \ | _ / / _` | | '_ \ | |/ / +# __/ | | __/ | | | | | | \ \ | (_| | | | | | | < +# |___/ \___| |_| |_| |_| \_\ \__,_| |_| |_| |_|\_\ +*/ +static bool genRank (char *outRank, size_t buflen, const char *min, const char *max, int rank) +{ + char locBuf [512]; + + char a,b,lmin,lmax; + a = min[strlen(min)-rank]; + b = max[strlen(max)-rank]; + + lmin = MININT (a,b); + lmax = MAXINT (a,b); + + if ((lmin == '0') && (lmax == '9')) { + strcpy (locBuf, "\\d"); + } else if (lmin == lmax) { + locBuf[0] = lmin; + locBuf[1] = 0; + } else if (lmax == (lmin+1)) { + sprintf (locBuf, "[%c%c]", lmin, lmax); + } else { + sprintf (locBuf, "[%c-%c]", lmin, lmax); + } + + CHECK_AND_RETURN (outRank); +} + +/* +# __ _ _____ _ _____ +# / _` | | __ \ | | | __ \ +# | (_| | ___ _ __ | |__) | ___ ___ | |_ | |__) | __ _ _ __ +# \__, | / _ \ | '_ \ | ___/ / _ \ / __| | __| | _ / / _` | | '_ \ +# __/ | | __/ | | | | | | | (_) | \__ \ \ |_ | | \ \ | (_| | | | | | +# |___/ \___| |_| |_| |_| \___/ |___/ \__| |_| \_\ \__,_| |_| |_| +*/ +static bool genPostRank (char *postRank, size_t buflen, int rank) +{ + char locBuf [512]; + + if (rank <= 1) { + strcpy (locBuf, ""); + } else if (rank == 2) { + sprintf (locBuf, "\\d"); + } else { + sprintf (locBuf, "\\d{%d}", rank -1); + } + + CHECK_AND_RETURN (postRank); +} + +/* +# _ _ +# | | | | +# ___ _ _ | |__ ___ | |_ _ __ +# / __| | | | | | '_ \ / __| | __| | '__| +# \__ \ | |_| | | |_) | \__ \ \ |_ | | +# |___/ \__,_| |_.__/ |___/ \__| |_| +*/ +static bool substr (char *substring, size_t buflen, const char* expr, size_t pos, size_t len) +{ + char locBuf [512]; + size_t i, j=0; + + len = MAXINT (0, MININT (len, strlen (expr) - pos)); + for (i=pos; i<(pos+len); i++) { + locBuf[j++]= expr[i]; + } + locBuf[j] = 0; + + // printf ("DBG> substr ('%s', %d, %d) = '%s'\n", expr, pos, len, locBuf); + CHECK_AND_RETURN (substring); +} + +/* +# +# +# _ __ ___ __ __ ___ _ __ ___ ___ +# | '__| / _ \ \ \ / / / _ \ | '__| / __| / _ \ +# | | | __/ \ V / | __/ | | \__ \ | __/ +# |_| \___| \_/ \___| |_| |___/ \___| +*/ +static char* reverse (char *string) +{ + char *locBuf ; + int i; + size_t len = strlen (string); + + locBuf = malloc (len+1); + for (i=len-1; i >= 0; i--) { + locBuf[len-i-1]= string[i]; + //printf ("DBG> reverse locBuf[%d]= %c\n",len- i-1, string[i]); + } + locBuf [len] = 0; + + // printf ("DBG> reverse '%s' = '%s'\n", string, locBuf); + strcpy (string, locBuf); + free (locBuf); + return (string); +} + +static char* longtoa (char *string, size_t buflen, long n) +{ + snprintf (string, buflen, "%ld", n); + return (string); +} + + +/* +# _ __ +# | '_ \ +# | |_) | ___ _ __ _ __ +# | .__/ / _ \ | '__| | '__| +# | | | __/ | | | | +# |_| \___| |_| |_| +*/ +static bool perr (const char* func, const char *fmt, ...) +{ + char err[4096], buffer[2048]; + va_list args; + va_start( args, fmt ); + vsprintf( buffer, fmt, args ); + va_end( args ); + + + sprintf (err, "Erreur %s @ %s\n", buffer, func); + fprintf (stderr, err); + return (fail); +} -- cgit v1.1 From df1997b6b4a7bb0a7cf5cf9f2b0d24d94af0213c Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:06:00 +0000 Subject: Utilisateur : Fcolin Date : 22/09/06 Heure : 14:54 Créé Commentaire: (vss 1) --- Ivy/intervalRegexp.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 Ivy/intervalRegexp.h (limited to 'Ivy') diff --git a/Ivy/intervalRegexp.h b/Ivy/intervalRegexp.h new file mode 100644 index 0000000..c1176ff --- /dev/null +++ b/Ivy/intervalRegexp.h @@ -0,0 +1,14 @@ +#ifndef INTERVALREGEXP_H +#define INTERVALREGEXP_H + +#ifdef __cplusplus +extern "C" { +#endif + +int regexpGen (char *regexp, size_t buflen, long min, long max, int flottant); + +#ifdef __cplusplus +} +#endif + +#endif -- cgit v1.1