mirror of
https://github.com/github/codeql.git
synced 2025-12-17 01:03:14 +01:00
Fix/add doc comments
This commit is contained in:
@@ -771,15 +771,16 @@ namespace Semmle.Extraction.CSharp.DependencyFetching
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Computes a unique temp directory for the packages associated
|
/// Returns the full path to a temporary directory with the given subfolder name.
|
||||||
/// with this source tree. Use a SHA1 of the directory name.
|
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <returns>The full path of the temp directory.</returns>
|
|
||||||
private static string ComputeTempDirectoryPath(string subfolderName)
|
private static string ComputeTempDirectoryPath(string subfolderName)
|
||||||
{
|
{
|
||||||
return Path.Combine(FileUtils.GetTemporaryWorkingDirectory(out _), subfolderName);
|
return Path.Combine(FileUtils.GetTemporaryWorkingDirectory(out _), subfolderName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Computes a unique temporary directory path based on the source directory and the subfolder name.
|
||||||
|
/// </summary>
|
||||||
private static string ComputeTempDirectoryPath(string srcDir, string subfolderName)
|
private static string ComputeTempDirectoryPath(string srcDir, string subfolderName)
|
||||||
{
|
{
|
||||||
return Path.Combine(FileUtils.GetTemporaryWorkingDirectory(out _), FileUtils.ComputeHash(srcDir), subfolderName);
|
return Path.Combine(FileUtils.GetTemporaryWorkingDirectory(out _), FileUtils.ComputeHash(srcDir), subfolderName);
|
||||||
|
|||||||
@@ -86,7 +86,7 @@ namespace Semmle.Util
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Computes the hash of <paramref name="filePath"/>.
|
/// Computes the hash of the file at <paramref name="filePath"/>.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public static string ComputeFileHash(string filePath)
|
public static string ComputeFileHash(string filePath)
|
||||||
{
|
{
|
||||||
@@ -95,6 +95,9 @@ namespace Semmle.Util
|
|||||||
return GetHashString(sha);
|
return GetHashString(sha);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Computes the hash of <paramref name="input"/>.
|
||||||
|
/// </summary>
|
||||||
public static string ComputeHash(string input)
|
public static string ComputeHash(string input)
|
||||||
{
|
{
|
||||||
var bytes = Encoding.Unicode.GetBytes(input);
|
var bytes = Encoding.Unicode.GetBytes(input);
|
||||||
|
|||||||
Reference in New Issue
Block a user