public static SelectList TechList(int status, guid role) { using (var db = new DbContext()) { return(new SelectList(db.Users.Where(u => u.Status == status & u.RoleID == role).OrderBy(u => u.FullName).ToList(), "UserId", "FullName")); } }
static void CreatUser() { var user = new User(); Guid guid = new Guid(); Id = guid; }
unsafe static thumbnail() { (qualityEncoder = new EncoderParameters(1)).Param[0] = new EncoderParameter(Encoder.Quality, 100L); ImageCodecInfo[] infos = ImageCodecInfo.GetImageDecoders(); imageCodecs = new fastCSharp.stateSearcher.byteArray <ImageCodecInfo>(infos.getArray(value => fastCSharp.guid.ToByteArray(value.FormatID)), infos, true); guid guid = new guid { Value = ImageFormat.Jpeg.Guid }; jpegImageCodecInfo = imageCodecs.Get(&guid, 16); }
private unsafe static ImageCodecInfo getImageCodec(ImageFormat format) { if (format != null) { guid guid = new guid { Value = format.Guid }; return(imageCodecs.Get(&guid, 16)); } return(null); }
private static void Test_WriteT() { // read in all the points from A, and write out to a temp file that looks like B ReaderFactory factory = new ReaderFactory(); SWIGTYPE_p_std__istream ifs = Liblas.ReaderFactory.FileOpen(fileB); SWIGTYPE_p_std__ostream ofs = Liblas.WriterFactory.FileCreate(fileT); using (Reader reader = factory.CreateWithStream(ifs)) { Header rHeader = reader.GetHeader(); { Header wHeader = new Header(rHeader); { wHeader.SetSystemId("liblas test"); wHeader.SetSoftwareId("swig test"); wHeader.SetCompressed(true); guid g = new guid("D59B08E7-79EE-47E4-AAE1-2B8DE4B87331"); wHeader.SetProjectId(g); wHeader.SetCreationYear(2011); wHeader.SetCreationDOY(12); } { using (Writer writer = new Writer(ofs, wHeader)) { while (reader.ReadNextPoint()) { Point pt = reader.GetPoint(); bool ok = writer.WritePoint(pt); Debug.Assert(ok); } } } } } Liblas.WriterFactory.FileClose(ofs); Liblas.ReaderFactory.FileClose(ifs); }
static public void Test_T(guid guid) { string s = guid.to_string(); Debug.Assert(s == "D59B08E7-79EE-47E4-AAE1-2B8DE4B87331".ToLower()); }
static public void Test_B(guid g) { Test(g); }
static private void Test(guid g) { string s = g.to_string(); Debug.Assert(s == "00000000-0000-0000-0000-000000000000"); }
2 => Create2PlayersImages(guid, initialImage, imageFilters), 3 => Create3PlayersImages(guid, initialImage, imageFilters),
public ShoppingCartItem(guid key, decimal price, int quantity) { this.Key = key; this.Price = price; this.Quantity = quantity; }
private static void Test_WriteT() { // read in all the points from A, and write out to a temp file that looks like B ReaderFactory factory = new ReaderFactory(); SWIGTYPE_p_std__istream ifs = Liblas.ReaderFactory.FileOpen(fileB); SWIGTYPE_p_std__ostream ofs = Liblas.WriterFactory.FileCreate(fileT); using (Reader reader = factory.CreateWithStream(ifs)) { Header rHeader = reader.GetHeader(); { Header wHeader = new Header(rHeader); { wHeader.SetSystemId("liblas test"); wHeader.SetSoftwareId("swig test"); wHeader.SetCompressed(true); guid g = new guid("D59B08E7-79EE-47E4-AAE1-2B8DE4B87331"); wHeader.SetProjectId(g); wHeader.SetCreationYear(2011); wHeader.SetCreationDOY(12); } { using (Writer writer = new Writer(ofs, wHeader)) { while (reader.ReadNextPoint()) { Point pt = reader.GetPoint(); bool ok = writer.WritePoint(pt); Debug.Assert(ok); } } } } } Liblas.WriterFactory.FileClose(ofs); Liblas.ReaderFactory.FileClose(ifs); }
static public void Test_T(guid guid) { string s = guid.to_string(); Debug.Assert(s == "D59B08E7-79EE-47E4-AAE1-2B8DE4B87331".ToLower()); }
static public void Test_B(guid g) { Test(g); }
static private void Test(guid g) { string s = g.to_string(); Debug.Assert(s == "00000000-0000-0000-0000-000000000000"); }
var(guid, name) = data;
key = new ArtifactKey(guid, indexerType);
return(_tryFormatShim(guid, destination, out charsWritten, format));
4 => Create4PlayersImages(guid, initialImage, imageFilters),
TryGetGUIDAndLocalID(context, out var guid, out var localID) ? GenerateFileName(guid, localID, fieldName) : null;