Skip to content

Commit

Permalink
Lsp (#35)
Browse files Browse the repository at this point in the history
* new crash report manager service and we change the way we are generating services

* more fixy things

* start on removing some todos

* resolve todos

* fix them buggies

* finish up
  • Loading branch information
artehe authored Apr 17, 2024
1 parent fdf7334 commit f24412e
Show file tree
Hide file tree
Showing 30 changed files with 1,181 additions and 313 deletions.
2 changes: 1 addition & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ dotnet_style_qualification_for_event = false:silent
dotnet_diagnostic.CA1835.severity = suggestion
dotnet_style_prefer_collection_expression = true:suggestion
dotnet_diagnostic.CA1838.severity = suggestion
dotnet_diagnostic.CA1848.severity = suggestion
dotnet_diagnostic.CA1848.severity = silent
dotnet_diagnostic.CA1852.severity = suggestion
dotnet_diagnostic.CA1863.severity = suggestion
dotnet_diagnostic.CA1304.severity = warning
Expand Down
23 changes: 23 additions & 0 deletions Netimobiledevice/Afc/AfcReadDirectoryRequest.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
using Netimobiledevice.Extentions;
using System.Collections.Generic;
using System.Text;

namespace Netimobiledevice.Afc
{
internal class AfcReadDirectoryRequest
{
public CString Filename { get; }

public AfcReadDirectoryRequest(string filename)
{
Filename = new CString(filename, Encoding.UTF8);
}

public byte[] GetBytes()
{
List<byte> bytes = new List<byte>();
bytes.AddRange(Filename.Bytes);
return bytes.ToArray();
}
}
}
24 changes: 24 additions & 0 deletions Netimobiledevice/Afc/AfcReadDirectoryResponse.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Netimobiledevice.Afc
{
internal class AfcReadDirectoryResponse
{
public List<string> Filenames { get; }

public AfcReadDirectoryResponse(List<string> filenames)
{
Filenames = filenames;
}

public static AfcReadDirectoryResponse Parse(byte[] data)
{
string decodedData = Encoding.UTF8.GetString(data);
List<string> seperatedData = decodedData.Split('\0').ToList();
seperatedData.RemoveAt(seperatedData.Count - 1);
return new AfcReadDirectoryResponse(seperatedData);
}
}
}
19 changes: 19 additions & 0 deletions Netimobiledevice/Afc/AfcRmRequest.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Netimobiledevice.Extentions;

namespace Netimobiledevice.Afc
{
internal class AfcRmRequest
{
public CString Filename { get; }

public AfcRmRequest(CString filename)
{
Filename = filename;
}

public byte[] GetBytes()
{
return Filename.Bytes;
}
}
}
Loading

0 comments on commit f24412e

Please sign in to comment.