This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Approved | |
{ | |
public virtual Guid Id { get; set; } | |
public virtual IEnumerable<Entry> Entries { get; set; } | |
} | |
public class Entry | |
{ | |
public virtual Guid Id { get; set; } | |
public virtual Guid Description { get; set; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Approved | |
{ | |
public virtual Guid Id { get; set; } | |
public virtual IEnumerable<Guid> EntryIds { get; set; } | |
} | |
// Mapping, Table specifies the table name to use, element specifies the column the Guid is stored in, KeyColumn specifies the foreign key in the table to link back to the parent Approved item | |
HasMany(x => x.EntryIds) | |
.Table("ApprovedEntryIds") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Sometimes it's easier to make assumptions about performance as a trade off for simplified code, but why not make it easy to notify us when that assumption is violated? Next step might be StopAndNotify | |
// Usage | |
using (new NotifyIfTakesMoreThan(TimeSpan.FromMinutes(5), "XYZ Import - checking all data instead of more complex code to optimize it")) | |
{ | |
//operation | |
} | |
// Implementation |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
desc "Setup dependencies for nuget packages" | |
task :dep do | |
package_folder = File.expand_path('src\\packages') | |
packages = FileList["**/packages.config"].map{|f| File.expand_path(f)} | |
packages.each do |file| | |
sh %Q{nuget install #{file} /OutputDirectory #{package_folder}} | |
end | |
end |
NewerOlder