This file contains hidden or 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
# Criar dump quando o processo consumir 40% da CPU por pelo menos 5 segundos | |
procdump -c 40 -s 5 -ma pid-do-processo/nome-do-processo | |
# Criar dump quando o processo consumir 800mb de memória por pelo menos 5 segundos | |
procdump -m 800 -s 5 -ma pid-do-processo/nome-do-processo | |
# Criar dump quando o processo disparar uma exception que contém "zero" na mensagem | |
procdump -e 1 -f zero -ma pid-do-processo/nome-do-processo | |
This file contains hidden or 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
.namespace csharpfeatures | |
{ | |
.class private auto ansi beforefieldinit MainClass | |
extends [mscorlib]System.Object | |
{ | |
// method line 1 | |
.method public hidebysig specialname rtspecialname | |
instance default void '.ctor' () cil managed | |
{ |
This file contains hidden or 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
[TestFixture ()] | |
public class StringInterpolationTests | |
{ | |
[Test ()] | |
public void TestCase01 () | |
{ | |
var nome = "Márcio"; | |
var idade = 31; | |
var resultadoExperado = "Nome: Márcio, Idade: 31"; |
This file contains hidden or 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
var nome = "Márcio"; | |
var idade = 31; | |
var stringFormat = string.Format("Nome: {0}, Idade: {1}", nome, idade); | |
var stringInterpolation = $"Nome: {nome}, Idade: {idade}"; |
This file contains hidden or 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
[BefTestClass(Profile = "Desenvolvimento")] | |
public class Desenvolvimento | |
{ | |
[Test] | |
public void Test() | |
{ | |
Assert.AreEqual("WES_DESENVOLVIMENTO", AppContext.Administration.DefaultSystemInstanceName); | |
} | |
} | |
This file contains hidden or 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
<configuration> | |
<configSections> | |
<section name="Bit" type="Benner.Tecnologia.Business.Test.Bit, Benner.Tecnologia.Business.Test" /> | |
</configSections> | |
<Bit> | |
<Profiles> | |
<Profile Name="Desenvolvimento" | |
Default="True" | |
SuperServerHost="Servidor" |
This file contains hidden or 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
Show hidden characters
{ | |
"cmd": ["gcc", "${file}", "-o", "${file_path}/${file_base_name}"], | |
"file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:? (.*)$", | |
"working_dir": "${file_path}", | |
"selector": "source.c", | |
"variants": | |
[ | |
{ | |
"name": "Run", |
This file contains hidden or 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
var uri = new Uri("http://www.seusite.com/arquivos/arquivo.jpg"); | |
var nomeDoArquivo = string.Empty; | |
if(uri.IsFile) | |
nomeDoArquivo = Path.GetFileName(uri.LocalPath); |
This file contains hidden or 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
for var i = 0; i < 10; ++i{ | |
if(i % 2 == 0){ | |
println(i); | |
} | |
} |
This file contains hidden or 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
var livros = ["A Sociedade do Anel", "As Duas Torres", "O Retorno do Rei"] | |
for livro in livros{ | |
println(livro); | |
} |
NewerOlder