Logo ROOT  
Reference Guide
ROOT::Experimental::RBrowser Class Reference

Web-based ROOT file browser.

RBrowser requires one of the supported web browsers:

  • Google Chrome (preferable)
  • Mozilla Firefox

Definition at line 27 of file RBrowser.hxx.

Public Member Functions

 RBrowser (bool use_rcanvas=true)
 constructor More...
 
virtual ~RBrowser ()
 destructor More...
 
void AddRCanvas ()
 
void AddTCanvas ()
 
bool GetUseRCanvas () const
 
void Hide ()
 hide Browser More...
 
void SetUseRCanvas (bool on=true)
 
void SetWorkingPath (const std::string &path)
 Set working path in the browser. More...
 
void Show (const RWebDisplayArgs &args="", bool always_start_new_browser=false)
 show Browser in specified place More...
 

Protected Member Functions

void AddInitWidget (const std::string &kind)
 Create new widget and send init message to the client. More...
 
std::shared_ptr< RBrowserWidgetAddWidget (const std::string &kind)
 Creates new widget. More...
 
void CloseTab (const std::string &name)
 Close and delete specified widget. More...
 
std::shared_ptr< RBrowserWidgetFindWidget (const std::string &name) const
 Returns active geometry viewer (if any) More...
 
std::shared_ptr< RBrowserWidgetGetActiveWidget () const
 
std::string GetCurrentWorkingDirectory ()
 Return the current directory of ROOT. More...
 
std::vector< std::string > GetRootHistory ()
 Get content of history file. More...
 
std::vector< std::string > GetRootLogs ()
 Get content of log file. More...
 
std::string NewWidgetMsg (std::shared_ptr< RBrowserWidget > &widget)
 Create message which send to client to create new widget. More...
 
std::string ProcessBrowserRequest (const std::string &msg)
 Process browser request. More...
 
std::string ProcessDblClick (std::vector< std::string > &args)
 Process dbl click on browser item. More...
 
void ProcessMsg (unsigned connid, const std::string &arg)
 Process received message from the client. More...
 
long ProcessRunMacro (const std::string &file_path)
 Process file save command in the editor. More...
 
void ProcessSaveFile (const std::string &fname, const std::string &content)
 Process file save command in the editor. More...
 
void SendInitMsg (unsigned connid)
 Process client connect. More...
 

Protected Attributes

std::string fActiveWidgetName
 ! name of active widget More...
 
RBrowserData fBrowsable
 ! central browsing element More...
 
unsigned fConnId {0}
 ! default connection id More...
 
std::string fTitle
 ! title More...
 
bool fUseRCanvas {false}
 ! which canvas should be used More...
 
std::shared_ptr< RWebWindowfWebWindow
 ! web window to browser More...
 
int fWidgetCnt {0}
 ! counter for created widgets More...
 
std::vector< std::shared_ptr< RBrowserWidget > > fWidgets
 ! all browser widgets More...
 

#include <ROOT/RBrowser.hxx>

Constructor & Destructor Documentation

◆ RBrowser()

RBrowser::RBrowser ( bool  use_rcanvas = true)

constructor

Definition at line 134 of file RBrowser.cxx.

◆ ~RBrowser()

RBrowser::~RBrowser ( )
virtual

destructor

Definition at line 167 of file RBrowser.cxx.

Member Function Documentation

◆ AddInitWidget()

void RBrowser::AddInitWidget ( const std::string &  kind)
protected

Create new widget and send init message to the client.

Definition at line 365 of file RBrowser.cxx.

◆ AddRCanvas()

void ROOT::Experimental::RBrowser::AddRCanvas ( )
inline

Definition at line 72 of file RBrowser.hxx.

◆ AddTCanvas()

void ROOT::Experimental::RBrowser::AddTCanvas ( )
inline

Definition at line 71 of file RBrowser.hxx.

◆ AddWidget()

std::shared_ptr< RBrowserWidget > RBrowser::AddWidget ( const std::string &  kind)
protected

Creates new widget.

Definition at line 336 of file RBrowser.cxx.

◆ CloseTab()

void RBrowser::CloseTab ( const std::string &  name)
protected

Close and delete specified widget.

Definition at line 389 of file RBrowser.cxx.

◆ FindWidget()

std::shared_ptr< RBrowserWidget > RBrowser::FindWidget ( const std::string &  name) const
protected

Returns active geometry viewer (if any)

Definition at line 375 of file RBrowser.cxx.

◆ GetActiveWidget()

std::shared_ptr< RBrowserWidget > ROOT::Experimental::RBrowser::GetActiveWidget ( ) const
inlineprotected

Definition at line 45 of file RBrowser.hxx.

◆ GetCurrentWorkingDirectory()

std::string RBrowser::GetCurrentWorkingDirectory ( )
protected

Return the current directory of ROOT.

Definition at line 481 of file RBrowser.cxx.

◆ GetRootHistory()

std::vector< std::string > RBrowser::GetRootHistory ( )
protected

Get content of history file.

Definition at line 402 of file RBrowser.cxx.

◆ GetRootLogs()

std::vector< std::string > RBrowser::GetRootLogs ( )
protected

Get content of log file.

Definition at line 425 of file RBrowser.cxx.

◆ GetUseRCanvas()

bool ROOT::Experimental::RBrowser::GetUseRCanvas ( ) const
inline

Definition at line 68 of file RBrowser.hxx.

◆ Hide()

void RBrowser::Hide ( )

hide Browser

Hide ROOT Browser.

Definition at line 324 of file RBrowser.cxx.

◆ NewWidgetMsg()

std::string RBrowser::NewWidgetMsg ( std::shared_ptr< RBrowserWidget > &  widget)
protected

Create message which send to client to create new widget.

Definition at line 489 of file RBrowser.cxx.

◆ ProcessBrowserRequest()

std::string RBrowser::ProcessBrowserRequest ( const std::string &  msg)
protected

Process browser request.

Definition at line 175 of file RBrowser.cxx.

◆ ProcessDblClick()

std::string RBrowser::ProcessDblClick ( std::vector< std::string > &  args)
protected

Process dbl click on browser item.

Definition at line 218 of file RBrowser.cxx.

◆ ProcessMsg()

void RBrowser::ProcessMsg ( unsigned  connid,
const std::string &  arg 
)
protected

Process received message from the client.

Definition at line 498 of file RBrowser.cxx.

◆ ProcessRunMacro()

long RBrowser::ProcessRunMacro ( const std::string &  file_path)
protected

Process file save command in the editor.

Definition at line 210 of file RBrowser.cxx.

◆ ProcessSaveFile()

void RBrowser::ProcessSaveFile ( const std::string &  fname,
const std::string &  content 
)
protected

Process file save command in the editor.

Definition at line 199 of file RBrowser.cxx.

◆ SendInitMsg()

void RBrowser::SendInitMsg ( unsigned  connid)
protected

Process client connect.

Definition at line 446 of file RBrowser.cxx.

◆ SetUseRCanvas()

void ROOT::Experimental::RBrowser::SetUseRCanvas ( bool  on = true)
inline

Definition at line 69 of file RBrowser.hxx.

◆ SetWorkingPath()

void RBrowser::SetWorkingPath ( const std::string &  path)

Set working path in the browser.

Definition at line 612 of file RBrowser.cxx.

◆ Show()

void RBrowser::Show ( const RWebDisplayArgs args = "",
bool  always_start_new_browser = false 
)

show Browser in specified place

Show or update RBrowser in web window If web window already started - just refresh it like "reload" button does If no web window exists or.

Parameters
always_start_new_browserconfigured, starts new window

Definition at line 312 of file RBrowser.cxx.

Member Data Documentation

◆ fActiveWidgetName

std::string ROOT::Experimental::RBrowser::fActiveWidgetName
protected

! name of active widget

Definition at line 35 of file RBrowser.hxx.

◆ fBrowsable

RBrowserData ROOT::Experimental::RBrowser::fBrowsable
protected

! central browsing element

Definition at line 41 of file RBrowser.hxx.

◆ fConnId

unsigned ROOT::Experimental::RBrowser::fConnId {0}
protected

! default connection id

Definition at line 32 of file RBrowser.hxx.

◆ fTitle

std::string ROOT::Experimental::RBrowser::fTitle
protected

! title

Definition at line 31 of file RBrowser.hxx.

◆ fUseRCanvas

bool ROOT::Experimental::RBrowser::fUseRCanvas {false}
protected

! which canvas should be used

Definition at line 34 of file RBrowser.hxx.

◆ fWebWindow

std::shared_ptr<RWebWindow> ROOT::Experimental::RBrowser::fWebWindow
protected

! web window to browser

Definition at line 39 of file RBrowser.hxx.

◆ fWidgetCnt

int ROOT::Experimental::RBrowser::fWidgetCnt {0}
protected

! counter for created widgets

Definition at line 37 of file RBrowser.hxx.

◆ fWidgets

std::vector<std::shared_ptr<RBrowserWidget> > ROOT::Experimental::RBrowser::fWidgets
protected

! all browser widgets

Definition at line 36 of file RBrowser.hxx.


The documentation for this class was generated from the following files: