OpenCores
URL https://opencores.org/ocsvn/riscv_vhdl/riscv_vhdl/trunk

Subversion Repositories riscv_vhdl

[/] [riscv_vhdl/] [trunk/] [debugger/] [src/] [common/] [iattr.h] - Blame information for rev 4

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 4 sergeykhbr
/*
2
 *  Copyright 2018 Sergey Khabarov, sergeykhbr@gmail.com
3
 *
4
 *  Licensed under the Apache License, Version 2.0 (the "License");
5
 *  you may not use this file except in compliance with the License.
6
 *  You may obtain a copy of the License at
7
 *
8
 *      http://www.apache.org/licenses/LICENSE-2.0
9
 *
10
 *  Unless required by applicable law or agreed to in writing, software
11
 *  distributed under the License is distributed on an "AS IS" BASIS,
12
 *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
 *  See the License for the specific language governing permissions and
14
 *  limitations under the License.
15
 */
16
 
17
#ifndef __DEBUGGER_IATTRIBUTE_H__
18
#define __DEBUGGER_IATTRIBUTE_H__
19
 
20
#include <iface.h>
21
 
22
namespace debugger {
23
 
24
static const char *const IFACE_ATTRIBUTE = "IAttribute";
25
 
26
class IAttribute : public IFace {
27
 public:
28
    IAttribute() :
29
        IFace(IFACE_ATTRIBUTE), attr_name_(NULL), attr_descr_(NULL) {}
30
 
31
    virtual void allocAttrName(const char *name) = 0;
32
    virtual void freeAttrName() = 0;
33
    virtual const char *getAttrName() { return attr_name_; }
34
 
35
    virtual void allocAttrDescription(const char *descr) = 0;
36
    virtual void freeAttrDescription() = 0;
37
    virtual const char *getAttrDescription() { return attr_descr_; }
38
 
39
    virtual void postinitAttribute() {}
40
 
41
 protected:
42
    char *attr_name_;
43
    char *attr_descr_;
44
};
45
 
46
}  // namespace debugger
47
 
48
#endif  // __DEBUGGER_IATTRIBUTE_H__

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.