Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 0 additions & 34 deletions java/ql/src/semmle/code/FileSystem.qll
Original file line number Diff line number Diff line change
Expand Up @@ -151,33 +151,6 @@ class Container extends @container, Top {
* This is the absolute path of the container.
*/
override string toString() { result = getAbsolutePath() }

/**
* DEPRECATED: use `getAbsolutePath()`, `getBaseName()` or `getStem()` instead.
*
* Gets the name of this container.
*/
deprecated string getName() { result = getAbsolutePath() }

/**
* DEPRECATED: use `getBaseName()` or `getStem()` instead.
*
* The short name of this container, excluding its path and (for files) extension.
*
* For folders, the short name includes the extension (if any), so the short name
* of the folder with absolute path `/home/user/.m2` is `.m2`.
*/
deprecated string getShortName() {
folders(this, _, result) or
files(this, _, result, _, _)
}

/**
* DEPRECATED: use `getAbsolutePath()` instead.
*
* Gets the full name of this container, including its path and extension (if any).
*/
deprecated string getFullName() { result = getAbsolutePath() }
}

/** A folder. */
Expand All @@ -198,13 +171,6 @@ class File extends Container, @file {

/** Gets the URL of this file. */
override string getURL() { result = "file://" + this.getAbsolutePath() + ":0:0:0:0" }

/**
* DEPRECATED: use `getAbsolutePath()`, `getBaseName()` or `getStem()` instead.
*
* Holds if this file has the specified `name`.
*/
deprecated predicate hasName(string name) { name = this.getAbsolutePath() }
}

/**
Expand Down
8 changes: 4 additions & 4 deletions java/ql/src/semmle/code/java/Statement.qll
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ class IfStmt extends ConditionalStmt, @ifstmt {
* Gets the statement that is executed whenever the condition
* of this branch statement evaluates to `true`.
*/
override Stmt getTrueSuccessor() { result = getThen() }
deprecated override Stmt getTrueSuccessor() { result = getThen() }

/** Gets the `else` branch of this `if` statement. */
Stmt getElse() { result.isNthChildOf(this, 2) }
Expand Down Expand Up @@ -168,7 +168,7 @@ class ForStmt extends ConditionalStmt, @forstmt {
* Gets the statement that is executed whenever the condition
* of this branch statement evaluates to true.
*/
override Stmt getTrueSuccessor() { result = getStmt() }
deprecated override Stmt getTrueSuccessor() { result = getStmt() }

/**
* Gets a variable that is used as an iteration variable: it is defined,
Expand Down Expand Up @@ -228,7 +228,7 @@ class WhileStmt extends ConditionalStmt, @whilestmt {
* Gets the statement that is executed whenever the condition
* of this branch statement evaluates to true.
*/
override Stmt getTrueSuccessor() { result = getStmt() }
deprecated override Stmt getTrueSuccessor() { result = getStmt() }

/** Gets a printable representation of this statement. May include more detail than `toString()`. */
override string pp() { result = "while (...) " + this.getStmt().pp() }
Expand All @@ -249,7 +249,7 @@ class DoStmt extends ConditionalStmt, @dostmt {
* Gets the statement that is executed whenever the condition
* of this branch statement evaluates to `true`.
*/
override Stmt getTrueSuccessor() { result = getStmt() }
deprecated override Stmt getTrueSuccessor() { result = getStmt() }

/** Gets a printable representation of this statement. May include more detail than `toString()`. */
override string pp() { result = "do " + this.getStmt().pp() + " while (...)" }
Expand Down