# eric6.Utilities.ClassBrowsers.idlclbr

Parse a CORBA IDL file and retrieve modules, interfaces, methods and attributes.

Parse enough of a CORBA IDL file to recognize module, interface and method definitions and to find out the superclasses of an interface as well as its attributes.

It is based on the Python class browser found in this package.

### Global Attributes

SUPPORTED_TYPES
_commentsub
_getnext
_modules
_normalize

### Classes

Attribute | Class to represent a CORBA IDL attribute.
Function | Class to represent a CORBA IDL function.
Interface | Class to represent a CORBA IDL interface.
Module | Class to represent a CORBA IDL module.
VisibilityMixin | Mixin class implementing the notion of visibility.

### Functions

calculateEndline | Function to calculate the end line.
calculateMethodEndline | Function to calculate the end line.
readmodule_ex | Read a CORBA IDL file and return a dictionary of classes, functions and modules.
scan | Public method to scan the given source text.

## Attribute

Class to represent a CORBA IDL attribute.

### Derived from

ClbrBaseClasses.Attribute, VisibilityMixin

### Class Attributes

None

### Class Methods

None

### Methods

Attribute | Constructor

### Static Methods

None

#### Attribute (Constructor)

Attribute(module, name, file, lineno)

Constructor

module (str)
  name of the module containing this attribute
name (str)
  name of this attribute
file (str)
  filename containing this attribute
lineno (int)
  line number of the attribute definition

Up

## Function

Class to represent a CORBA IDL function.

### Derived from

ClbrBaseClasses.Function, VisibilityMixin

### Class Attributes

None

### Class Methods

None

### Methods

Function | Constructor

### Static Methods

None

#### Function (Constructor)

Function(module, name, file, lineno, signature='', separator=', ')

Constructor

module (str)
  name of the module containing this function
name (str)
  name of this function
file (str)
  filename containing this function
lineno (int)
  line number of the function definition
signature (str)
  parameter list of the function
separator (str)
  string separating the parameters

Up

## Interface

Class to represent a CORBA IDL interface.

### Derived from

ClbrBaseClasses.Class, VisibilityMixin

### Class Attributes

None

### Class Methods

None

### Methods

Interface | Constructor

### Static Methods

None

#### Interface (Constructor)

Interface(module, name, superClasses, file, lineno)

Constructor

module (str)
  name of the module containing this interface
name (str)
  name of this interface
superClasses (list of str)
  list of interface names this interface is inherited from
file (str)
  filename containing this interface
lineno (int)
  line number of the interface definition

Up

## Module

Class to represent a CORBA IDL module.

### Derived from

ClbrBaseClasses.Module, VisibilityMixin

### Class Attributes

None

### Class Methods

None

### Methods

Module | Constructor

### Static Methods

None

#### Module (Constructor)

Module(module, name, file, lineno)

Constructor

module (str)
  name of the module containing this module
name (str)
  name of this module
file (str)
  filename containing this module
lineno (int)
  line number of the module definition

Up

## VisibilityMixin

Mixin class implementing the notion of visibility.

### Derived from

ClbrBaseClasses.ClbrVisibilityMixinBase

### Class Attributes

None

### Class Methods

None

### Methods

VisibilityMixin | Constructor

### Static Methods

None

#### VisibilityMixin (Constructor)

VisibilityMixin()

Constructor

Up

## calculateEndline

calculateEndline(lineno, lines)

Function to calculate the end line.

lineno (int)
  line number to start at (one based)
lines (list of str)
  list of source lines

Returns:
  end line (one based)

Return Type:
  int

Up

## calculateMethodEndline

calculateMethodEndline(lineno, lines)

Function to calculate the end line.

lineno (int)
  line number to start at (one based)
lines (list of str)
  list of source lines

Returns:
  end line (one based)

Return Type:
  int

Up

## readmodule_ex

readmodule_ex(module, path=None)

Read a CORBA IDL file and return a dictionary of classes, functions and modules.

module (str)
  name of the CORBA IDL file
path (list of str)
  path the file should be searched in

Returns:
  the resulting dictionary

Return Type:
  dict

Up

## scan

scan(src, file, module)

Public method to scan the given source text.

src (str)
  source text to be scanned
file (str)
  file name associated with the source text
module (str)
  module name associated with the source text

Returns:
  dictionary containing the extracted data

Return Type:
  dict

Up