Package com.android.ide.common.blame
Class SourceFile
- java.lang.Object
-
- com.android.ide.common.blame.SourceFile
-
- All Implemented Interfaces:
java.io.Serializable
@Immutable public final class SourceFile extends java.lang.Object implements java.io.SerializableRepresents a source file. Note: Since the same file may have different representations (eg a/b vs a/../a/b), it is better to use absolute files, otherwise the equals/hash method of this class may fail.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static SourceFileUNKNOWN
-
Constructor Summary
Constructors Constructor Description SourceFile(java.io.File sourceFile)SourceFile(java.io.File sourceFile, java.lang.String description)SourceFile(java.lang.String description)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)java.lang.StringgetDescription()java.io.FilegetSourceFile()java.lang.StringgetSourcePath()inthashCode()java.lang.Stringprint(boolean shortFormat)voidsetOverrideSourcePath(java.lang.String value)java.lang.StringtoString()
-
-
-
Field Detail
-
UNKNOWN
@NonNull public static final SourceFile UNKNOWN
-
-
Method Detail
-
setOverrideSourcePath
public void setOverrideSourcePath(@NonNull java.lang.String value)
-
getSourceFile
@Nullable public java.io.File getSourceFile()
-
getSourcePath
@Nullable public java.lang.String getSourcePath()
-
getDescription
@Nullable public java.lang.String getDescription()
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
toString
@NonNull public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
print
@NonNull public java.lang.String print(boolean shortFormat)
-
-