File: refactoring.h

package info (click to toggle)
kdevelop-python 24.12.3-1
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 12,640 kB
  • sloc: python: 183,048; cpp: 18,798; xml: 140; sh: 14; makefile: 9
file content (46 lines) | stat: -rw-r--r-- 901 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/*
    SPDX-FileCopyrightText: 2012 Sven Brauch <svenbrauch@googlemail.com>
    SPDX-FileCopyrightText: 2014 Miquel Sabaté <mikisabate@gmail.com>

    SPDX-License-Identifier: LGPL-2.0-or-later
*/

#ifndef REFACTORING_H_
#define REFACTORING_H_


#include <interfaces/context.h>
#include <language/codegen/basicrefactoring.h>

namespace KDevelop {
    class Declaration;
}


namespace Python {

class RefactoringCollector : public KDevelop::BasicRefactoringCollector
{
    Q_OBJECT

public:
    RefactoringCollector(const KDevelop::IndexedDeclaration &decl);

protected:
    void processUses(KDevelop::ReferencedTopDUContext topContext) override;
};

class Refactoring : public KDevelop::BasicRefactoring
{
    Q_OBJECT

public:
    explicit Refactoring(QObject *parent = nullptr);

protected:
    bool acceptForContextMenu(const KDevelop::Declaration *decl) override;
};

}

#endif // REFACTORING_H_