![]() CATEGORIES: BiologyChemistryConstructionCultureEcologyEconomyElectronicsFinanceGeographyHistoryInformaticsLawMathematicsMechanicsMedicineOtherPedagogyPhilosophyPhysicsPolicyPsychologySociologySportTourism |
SerializationBinder classserialization (continued) controlling, 619 controlling data, 624 converting types, 628 defining type for, 630 definition of, 611 formatter consistency, 615 of instance types, 619 ISerializable interface, 625, 630 matching deserialization method, 628 of multiple object graphs, 615 namespace, 623 .NET Framework support for, 612 of object graph, 614 of object set, 622 overriding assembly/type, 641 quick start for, 613 reflection and, 614 security and, 619 of singleton types, 633 special constructor type, 628 streaming contexts for, 631 surrogate selector chains, 639 surrogates for, 636 of type instances, 623 of types, 617, 618 of types, as different types, 633 to XML stream, 612, 614 when to avoid, 619 SerializationBinder class, 640 SerializationException exception, 615, 616, 618, 622 SerializationInfo object, 625, 628 Serialize method, 614 SerializeToMemory method, 614 Server garbage collection mode, 520 Servers, asynchronous implementation, 751 servicings, 161 SetAt method, 358 SetMaxThreads method, 724 SetMinThreads method, 724, 726 SetType method, 626, 635 SetValue method, 603 shared data, Parallel class and, 714 shim DLL, 554 short type, 112 SignalAndWait method, 805 signed data types, 117 signing files, 70 Silverlight applications AppDomains and, 574 processes run by, 687 Silverlight, threading model, 748 SimpleHybridLock method, 793 SimpleSpinLock method, 773 SimpleWaitLock method, 782, 784 simplifying applications, 682 SimulateNewMail method, 256 single-dimensional arrays, 375 single-instance applications, 781 Singleton class, 809 singleton types, serialization of, 633 Sleep method, 774 SN.exe, 68 delayed signing with, 77 Soap namespace, 614 SoapFormatter class, 614 object, 614 Software Publisher’s Digital ID for Authenticode, 488 SomeMethod method, 565, 566 SOS Debugging Extension, 525 source code compiling, 3 splitting types between, 159 protection, 267 source control, 159 spin locks, 773. See also thread synchronization spin loops, thread yielding and, 775 SpinLock method, 775 SpinLocks, 818 spinning threads, with hybrid locks, 791 SpinWait method, 774 Spy++, 683 SQL Server, AppDomains and, 575 stackalloc statement, 388 StackOverflowExceptions, 497
Strings stack space, 102 checking for, 489 stack trace, 461, 462 complete, 462 constructing, 462 interpreting, 463 StackTrace property, 461 Start method (Thread class), 679 StartNew method, 710 StartsWith method, comparing strings, 325 startup time, improving, 19, 21 starvation, thread, 684 state corruption destroying, 476 exception handling and, 474 FailFast method, 480 managed code and, 477 mitigating, 475 terminating process for, 477 state machines, returning threading model, 749 stateless encoding and decoding, 356 statements, checked and unchecked, 116 static classes, 158 static constructors. See type constructors defining on generic types, 273 static events, 152 static fields, 177 defining, 178 initializing, 189 memory leaks and, 510 static members interfaces and, 297 MarshalByRefObject class and, 567 static methods for arrays, 380 calling, 106 calling back, with delegates, 394 calling operator overload methods with, 194 for Char type, 318 extension attribute, 203 Finalize method and, 526 for Int32 variables, 768 thread safety, 759, 760 volatile keyword, 767 StaticDelegateDemo method, 394 Stop method (Parallel class), 716 streaming contexts for serialization, 631 StreamReader type, 350 streams, 656 StreamWriter type, 350, 537 finalization and, 538 String class hash table, accessing, 330 methods, 338 sealed, 323 string interning, 329 String objects. See strings immutability of, 569 String type, 112, 320 constructing, 320 interfaces and, 300 method overloads defined by, 325 as primitive type, 320 StringBuilder class, 198, 345 creating objects, 336 members, 337 methods, 338 StringBuilder type, 336 StringComparer class, 329 StringComparison type, 324 StringInfo, 333 strings base-64 encoding/decoding, 356 changing case of characters in, 325 character arrays, 337 characters, examining, 333 cloning, 335 comparing, 323 concatenating, 322 constructing, 320 constructing efficiently, 336 converting to bytes, 353 converting Unicode to MBCS, 350 copying, 335 custom formatter, 345 date formatting, 341 deleting securely, 358 encodings, 350
Strong Name utility (SN.exe) strings (continued) formatting, 344, 346 formatting multiple objects into, 344 immutability of, 323 interning, 329 mapping enumerated types to, 364 in metadata, 332 number formatting, 341 as object representation, 339 parsing, 348 pooling, 332 secure, 357 in source code, 321 uses for, 324 verbatim, 322 WinRT, 647 Strong Name utility (SN.exe), 68 strongly named assemblies characteristics of, 66 components of, 68 compressing, 74 creating, 67 deploying globally, 72 deploying privately, 79 obtaining key for, 68 referencing, 74 security of, 76 tamper resistant nature of, 75 unique identification of, 67 verification, 76 struct constraint, 287 Structured Exception Handling (SEH), 453. See also exceptions; exception handling structures. See value types Substring method, 335 SubstringByTextElements method, 333 SuppressFlow method, 695 SuppressMessage attribute, 440 SurrogateSelector objects, 639 surrogate types for serialization, 636 surrogates for Unicode elements, 333 suspending threads, 774 sync blocks, 794 array, 795 index, 105 initialization of, 795 optimizing, 795 public indexes, 797 relationships, 795 type objects and, 795 synchronization context task schedulers, 711 SynchronizationContext class, 749 synchronizing threads. See thread synchronization synchronous I/O operations, 752. See I/O operations FileStream objects and, 753 System Monitor, 524 System namespace, 22, 23 System.Collections.Generic namespace, 270 System.Decimal type, 118, 198 System.Diagnostics.ConditionalAttribute attribute, 206 System.Exception class, catching, state corruption and, 474 type, 460 SystemException type, 466 System.InvalidCastException type, 95 System.Object type, 26, 91 delete operator, 93 new operator, 92 protected methods, 92 public methods, 92 System.Reflection.AssemblyName class, 68 System.Runtime.ProfileOptimization class, 16 System.Text namespace, 97 System.Type object, type object pointer, 110 SZ arrays, 375
T TakeFromAny methods, 822 Task class vs. Barrier class, 814 vs. thread synchronization, 814 Task Manager, 670, 675 monitoring performance with, 675 Task objects, 701 arrays of, 710 Boolean properties for, 709 fields in, 707 ContinueWith task collections, 705 Date: 2016-03-03; view: 999
|