This file contains the implementation of the Window object.
More...
#include <iostream>
#include <cstdlib>
#include <cstdio>
#include "Window.h"
#include "roccom_assertion.h"
Go to the source code of this file.
|
| template<class Attr > |
| void | get_size_common (const Attr *a, int pid, int *nitem, int *ng) throw ( COM_exception) |
| |
| template<class Attr > |
| void | get_array_common (const Attr *a, int pid, Window::Pointer_descriptor &addr, int *strd, int *cap, bool is_const) throw (COM_exception) |
| |
| template<class Attr > |
| void | copy_array_common (const Attr *a, int pid, void *val, int v_strd, int v_size, int offset) throw (COM_exception) |
| |
This file contains the implementation of the Window object.
- See Also
- roccom_devel.h, Roccom_base.C
Definition in file Window.C.
| void copy_array_common |
( |
const Attr * |
a, |
|
|
int |
pid, |
|
|
void * |
val, |
|
|
int |
v_strd, |
|
|
int |
v_size, |
|
|
int |
offset |
|
) |
| |
| throw | ( | COM_exception |
| ) | | |
|
inline |
Definition at line 674 of file Window.C.
References append_frame, COM_ERR_NOT_A_WINDOW_ATTRIBUTE, Attribute::COPY_OUT, and offset().
Referenced by Window::copy_array().
677 if ( pid==0 && a->location() !=
'w')
679 ( a->fullname(), Window::copy_size));
681 const_cast<Attr*
>(a)->copy_array( val, v_strd, v_size,
real *8 function offset(vNorm, x2, y2, z2)
Encapsulates the states of an exception.
#define append_frame(s, frame)
Macro for appending the information about the given frame to the string s.
Definition at line 602 of file Window.C.
References append_frame, COM_ERR_ATTRIBUTE_CONST, COM_ERR_INVALID_DIMENSION, COM_ERR_INVALID_SIZE, COM_ERR_NOT_A_WINDOW_ATTRIBUTE, and Window::get_array().
Referenced by Window::get_array().
605 if ( !is_const && a->is_const() )
609 if ( pid==0 && a->location() !=
'w')
613 addr.
ptr = (
void*)(a->pointer());
615 addr.
n1 = a->capacity()*a->stride();
617 else if ( addr.
dim == 2) {
618 if ( a->stride()>=a->size_of_components()) {
619 addr.
n1 = a->stride();
620 addr.
n2 = a->capacity();
623 addr.
n1 = a->capacity();
624 addr.
n2 = a->size_of_components();
629 if ( addr.
dim==0 && (a->capacity()!=1 || a->size_of_components()!=1))
637 if ( cap) *cap = a->capacity();
638 if ( strd) *strd = a->stride();
Encapsulates the states of an exception.
void get_array(const std::string &aname, const int pane_id, Pointer_descriptor &addr, int *strd=NULL, int *cap=NULL, bool is_const=false)
Get the address associated with an attribute for a specific pane.
#define append_frame(s, frame)
Macro for appending the information about the given frame to the string s.
| void get_size_common |
( |
const Attr * |
a, |
|
|
int |
pid, |
|
|
int * |
nitem, |
|
|
int * |
ng |
|
) |
| |
| throw | ( | COM_exception |
| ) | | |
Definition at line 493 of file Window.C.
References append_frame, COM_ERR_NOT_A_WINDOW_ATTRIBUTE, and Window::get_size().
Referenced by Window::get_size().
496 if ( pid==0 && a->location() !=
'w')
500 if ( nitem) *nitem = a->size_of_items();
501 if ( ng) *ng = a->size_of_ghost_items();
void get_size(const std::string &aname, int pane_id, int *nitems, int *ng) const
Get the sizes of an attribute for a specific pane.
Encapsulates the states of an exception.
#define append_frame(s, frame)
Macro for appending the information about the given frame to the string s.