Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 23, 2006, 4:07:41 PM (18 years ago)
Author:
bensch
Message:

netlink quite nice

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/proxy/src/lib/util/filesys/net_link.h

    r9393 r9394  
     1/*!
     2 * @file net_link.h
     3 * @brief Definition of a NetLink class
     4 * NetLink is a File link to a page of file link to the Internet,
     5 * or the local file-system
     6 *
     7 * Opening a link should be made easy through this class
     8 *
     9 * !! DANGER IT IS POSSIBLE TO EXECUTE ALL PROGRAMMS WITH USER'S RIGHTS
     10 * !! ON THE DESIGNATED MACHINE
     11 * !! THIS CLASS SHOULD BE USED WITH CAUTION WHEN USING OVER IN NETWORK
     12 * !! MODE
     13 */
    114
    215#ifndef __NET_LINK_H__
     
    619#include <list>
    720
     21#include "threading.h"
     22
     23//! NetLink is a File and Link executer for Internet Links
     24/**
     25 * @example: NetLink("http://www.orxonox.net").openInBrowser();
     26 */
    827class NetLink
    928{
    1029public:
    11   NetLink(const std::string& );
     30  NetLink(const std::string& linkName);
    1231
    13   void execURL() const;
    14   int startURL(void* url);
    15 
     32  void openInBrowser() const;
    1633
    1734  static void setDefaultBrowser(const std::string& browserName);
    18   static const std::string& defaultBrowser();
     35  static const std::string& defaultBrowser() {  return NetLink::_browser; };
    1936
    2037private:
    21   static void buildBrowserList();
     38  static int openupInBrowser(void* url);
     39
     40  static std::list<std::string> buildBrowserList();
    2241
    2342
    2443private:
    25   std::string                    _link;
     44  std::string                     _link;             //!< Linkname
     45
    2646
    2747  // static lists.
     48  static OrxThread::Mutex         _mutex;            //!< One mutex to lock them all.
    2849  static std::string              _browser;
    2950  static std::list<std::string>   _browserList;
Note: See TracChangeset for help on using the changeset viewer.