diff options
Diffstat (limited to 'pt-br/csharp-pt.html.markdown')
| -rw-r--r-- | pt-br/csharp-pt.html.markdown | 44 | 
1 files changed, 22 insertions, 22 deletions
| diff --git a/pt-br/csharp-pt.html.markdown b/pt-br/csharp-pt.html.markdown index b6e95d36..2ff59296 100644 --- a/pt-br/csharp-pt.html.markdown +++ b/pt-br/csharp-pt.html.markdown @@ -59,7 +59,7 @@ namespace Learning.CSharp              Console.Write("World");              /////////////////////////////////////////////////// -            // Tpos e Variáveis +            // Tipos e Variáveis              //              // Declare uma variável usando <tipo> <nome>              /////////////////////////////////////////////////// @@ -95,8 +95,8 @@ namespace Learning.CSharp              float fooFloat = 234.5f; // Precision: 7 digits              // f is used to denote that this variable value is of type float -            // Decimal - a 128-bits data type, with more precision than other floating-point types, -            // suited for financial and monetary calculations +            // Decimal - um tipo de dados de 128 bits, com mais precisão do que outros tipos de ponto flutuante, +            // adequado para cálculos financeiros e monetários              decimal fooDecimal = 150.3m;              // Boolean - true & false @@ -294,9 +294,9 @@ on a new line! ""Wow!"", the masses cried";                  case 3:                      monthString = "March";                      break; -                // You can assign more than one case to an action -                // But you can't add an action without a break before another case -                // (if you want to do this, you would have to explicitly add a goto case x +                // Você pode declarar mais de um "case" para uma ação +                // Mas você não pode adicionar uma ação sem um "break" antes de outro "case" +                // (se você quiser fazer isso, você tem que explicitamente adicionar um "goto case x")                  case 6:                  case 7:                  case 8: @@ -336,28 +336,28 @@ on a new line! ""Wow!"", the masses cried";          }          /////////////////////////////////////// -        // CLASSES - see definitions at end of file +        // CLASSES - Veja definições no fim do arquivo          ///////////////////////////////////////          public static void Classes()          { -            // See Declaration of objects at end of file +            // Veja Declaração de objetos no fim do arquivo -            // Use new to instantiate a class +            // Use new para instanciar uma classe              Bicycle trek = new Bicycle(); -            // Call object methods -            trek.SpeedUp(3); // You should always use setter and getter methods +            // Chame métodos do objeto +            trek.SpeedUp(3); // Você deve sempre usar métodos setter e getter              trek.Cadence = 100; -            // ToString is a convention to display the value of this Object. +            // ToString é uma convenção para exibir o valor desse Objeto.              Console.WriteLine("trek info: " + trek.Info()); -            // Instantiate a new Penny Farthing +            // Instancie um novo Penny Farthing              PennyFarthing funbike = new PennyFarthing(1, 10);              Console.WriteLine("funbike info: " + funbike.Info());              Console.Read(); -        } // End main method +        } // Fim do método principal          // CONSOLE ENTRY A console application must have a main method as an entry point          public static void Main(string[] args) @@ -522,7 +522,7 @@ on a new line! ""Wow!"", the masses cried";              foreach (var key in responses.Keys)                  Console.WriteLine("{0}:{1}", key, responses[key]); -            // DYNAMIC OBJECTS (great for working with other languages) +            // OBJETOS DINÂMICOS (ótimo para trabalhar com outros idiomas)              dynamic student = new ExpandoObject();              student.FirstName = "First Name"; // No need to define class first! @@ -730,10 +730,10 @@ on a new line! ""Wow!"", the masses cried";              set { _hasTassles = value; }          } -        // You can also define an automatic property in one line -        // this syntax will create a backing field automatically. -        // You can set an access modifier on either the getter or the setter (or both) -        // to restrict its access: +        // Você também pode definir uma propriedade automática em uma linha +        // Esta sintaxe criará um campo de apoio automaticamente. +        // Você pode definir um modificador de acesso no getter ou no setter (ou ambos) +        // para restringir seu acesso:          public bool IsBroken { get; private set; }          // Properties can be auto-implemented @@ -834,7 +834,7 @@ on a new line! ""Wow!"", the masses cried";          bool Broken { get; } // interfaces can contain properties as well as methods & events      } -    // Class can inherit only one other class, but can implement any amount of interfaces +    // Classes podem herdar apenas de uma outra classe, mas podem implementar qualquer quantidade de interfaces.      class MountainBike : Bicycle, IJumpable, IBreakable      {          int damage = 0; @@ -854,8 +854,8 @@ on a new line! ""Wow!"", the masses cried";      }      /// <summary> -    /// Used to connect to DB for LinqToSql example. -    /// EntityFramework Code First is awesome (similar to Ruby's ActiveRecord, but bidirectional) +    /// Exemplo de como conectar-se ao DB via LinqToSql. +    /// EntityFramework First Code é impressionante (semelhante ao ActiveRecord de Ruby, mas bidirecional)      /// http://msdn.microsoft.com/en-us/data/jj193542.aspx      /// </summary>      public class BikeRepository : DbContext | 
