Skip to content

Commit

Permalink
Adapt Javadoc in reworked parts
Browse files Browse the repository at this point in the history
  • Loading branch information
smeyer198 committed Nov 18, 2023
1 parent 6a37027 commit d61c953
Show file tree
Hide file tree
Showing 6 changed files with 33 additions and 54 deletions.
10 changes: 5 additions & 5 deletions CryptoAnalysis/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -264,6 +264,11 @@
<artifactId>guava</artifactId>
<version>32.1.3-jre</version>
</dependency>
<dependency>
<groupId>org.ow2.asm</groupId>
<artifactId>asm</artifactId>
<version>9.3</version>
</dependency>
<dependency>
<groupId>de.fraunhofer.iem</groupId>
<artifactId>idealPDS</artifactId>
Expand Down Expand Up @@ -372,10 +377,5 @@
<version>2.15.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.ow2.asm/asm -->
<dependency>
<groupId>org.ow2.asm</groupId>
<artifactId>asm</artifactId>
<version>9.3</version>
</dependency>
</dependencies>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,6 @@ protected Map<String, CallSiteWithExtractedValue> extractValueAsString(String va
*
* @param callSite call site at which sootValue is involved
* @param allocSite allocation site at which sootValue is involved
* @param arrayLocal soot array local variable for which values are to be found
* @return extracted array values
*/
protected Map<String, CallSiteWithExtractedValue> extractSootArray(CallSiteWithParamIndex callSite,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ public void evaluate() {
/**
* Checks if a) the method that is called is the same as the method of
* this constraint and b) if the specified exception is caught.
*
* @param call the called statement
*/
public void evaluate(Statement call) {
try {
Expand All @@ -58,12 +60,12 @@ public void evaluate(Statement call) {
}

/**
* Returns whether the `trapped` unit ins trapped in the method body.
* Returns whether the `trapped` unit is trapped in the method body.
*
* @param body
* @param trap
* @param trapped
* @return Returns whether the `trapped` unit ins trapped in the method body.
* @param body the method's body
* @param trap the trap
* @param trapped the trapped unit
* @return Returns whether the `trapped` unit is trapped in the method body.
*/
public static boolean trapsUnit(final Body body, final Trap trap, final Unit trapped) {
boolean begun = false;
Expand All @@ -81,8 +83,8 @@ public static boolean trapsUnit(final Body body, final Trap trap, final Unit tra
/**
* Returns the handler, that catches the exception thrown by callee in the method.
*
* @param method in which callee is called.
* @param callee The called Method, throwing the exception.
* @param body The called Method, throwing the exception.
* @param unit Unit where callee is called.
* @param exception The called Method, throwing the exception.
* @return Returns the handler, that catches the exception thrown by callee in the method.
*/
Expand All @@ -96,6 +98,10 @@ public static Optional<Trap> getTrap(final Body body, final Unit unit, final Soo

/**
* Returns all units in the method body, excluding exception handlers.
*
* @param body the method's body
*
* @return units all collected units
*/
public static Collection<Unit> getUnits(Body body) {
Collection<Unit> units = new ArrayList<>();
Expand Down
2 changes: 2 additions & 0 deletions CryptoAnalysis/src/main/java/crypto/rules/CrySLException.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ public class CrySLException {
/**
* Construct a {@link CrySLException} from the fully qualified classname
* of the {@link Exception} to store.
*
* @param exception the exception's name
*/
public CrySLException(String exception) {
this.exception = exception;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,11 @@ public static MatcherTransition getErrorTransition(State from, Collection<SootMe
/**
* Match the called method against a declared method and checker whether
* the called method could actually be the declared one.
*
* @param called the called method
* @param declared the declared method
*
* @return true, if called and declared method match
*/
public static boolean matches(SootMethod called, SootMethod declared) {
// Name is equal
Expand All @@ -53,8 +58,13 @@ public static boolean matches(SootMethod called, SootMethod declared) {
}

/**
* Returns whether parent is a supertype of child, i.e. if they
* are the same, child implements or extends parent transitivly.
* Returns whether parent is a super type of child, i.e. if they
* are the same, child implements or extends parent transitively.
*
* @param child the child to check
* @param parent the parent to check against
*
* @return true, if parent is a super type of child
*/
public static boolean isSubtype(SootClass child, SootClass parent) {
if (child.equals(parent))
Expand Down Expand Up @@ -118,7 +128,7 @@ public boolean matches(SootMethod method) {
* defined here, to get the {@link CrySLMethod}s that were resolved to the
* matching {@link SootMethod}s.
*
* @param method
* @param method the given method
* @return The {@link CrySLMethod}'s matching the given soot method.
*/
public Optional<CrySLMethod> getMatching(SootMethod method) {
Expand Down
38 changes: 0 additions & 38 deletions dependencies.txt

This file was deleted.

0 comments on commit d61c953

Please sign in to comment.