SOL9 Sample: NetSession

SOL9 2.0 Samples

1 Screenshot


2 Source code

/*
 * NetSession.cpp 
 * Copyright (c) 2015 Antillia.com TOSHIYUKI ARAI. ALL RIGHTS RESERVED. 
 */


#include <sol/nm/NetSession.h>

#include <sol/nm/SessionInfo0.h>
#include <sol/nm/SessionInfo1.h>
#include <sol/nm/SessionInfo2.h>

#include <sol/Locale.h>

void _tmain(int argc, TCHAR** argv)
{
  Locale locale;

  try {
    wchar_t* server = NULL;

    NetSession netSession(server);


    SessionInfo0 info0;
    SessionInfo1 info1;
    SessionInfo2 info2;

    wchar_t* clientName = NULL;
    wchar_t* userName = NULL;

    netSession.enumerate(clientName, userName, info0);
    info0.display();
    printf("\n");

    netSession.enumerate(clientName, userName, info1);
    info1.display();
    printf("\n");

    netSession.enumerate(clientName, userName, info2);
    info2.display();
    
  } catch (...) {
    printf("Exception \n");
  }

  printf("\nOK. Please hit [enter] key.\n");
  getchar();
}

Last modified: 2 May 2016

Copyright (c) 2016 Antillia.com ALL RIGHTS RESERVED.