上一页 1 2 3 4 5 6 ··· 45 下一页
  2017年8月18日
摘要: databinding还能对布局的资源文件进行绑定。 本节参考代码。 阅读全文
posted @ 2017-08-18 15:42 lee0oo0 阅读(1677) 评论(0) 推荐(0) 编辑
摘要: 本节主要说Collection的字符串数组、List、SparseArray、Map的绑定。先看看xml的布局。 首先在<data>导入Collection的类型。&lt;是< 的转义符。获取值的时候使用@{ map[key] } 在binding设置值。 binding.setIndex(inde 阅读全文
posted @ 2017-08-18 15:13 lee0oo0 阅读(1939) 评论(0) 推荐(0) 编辑
摘要: 主的布局xml文件: 本布局一共包含3个include布局,第一个是一个普通的布局,里面没有<data></data>, 考虑的就是如何通过id获取控件的引用。binding.layoutInput.etName binding是绑定的对象,layoutInput和etName就是Id,至于为啥没有 阅读全文
posted @ 2017-08-18 11:55 lee0oo0 阅读(3278) 评论(0) 推荐(0) 编辑
摘要: 1. 在xml中,添加class的属性并设置为自定义名字2. 使用的时候就是自己自定义的名字了ContractBinding binding = DataBindingUtil.setContentView(this, R.layout.activity_custom_binding);本节参考代码。 阅读全文
posted @ 2017-08-18 11:02 lee0oo0 阅读(907) 评论(0) 推荐(0) 编辑
摘要: 1. 使用ActivityBasicBinding binding = DataBindingUtil.setContentView(this, R.layout.main);代替之前使用的setContentView2. 创建一个pojo的数据类,例如User3. main.xml这个布局添加,U 阅读全文
posted @ 2017-08-18 10:39 lee0oo0 阅读(253) 评论(0) 推荐(0) 编辑
  2015年5月1日
摘要: 数组:int[] numbers = {4, 5, 6, 1, 2, 3, -2, -1, 0};foreach (int i in numbers){ System.Console.WriteLine(i);} 阅读全文
posted @ 2015-05-01 22:11 lee0oo0 阅读(228) 评论(0) 推荐(0) 编辑
摘要: 学习获取终端输入的参数并且打印,以及使用循环。using System;public class CommandLine{ public static void Main(string[] args) // 需要参数 { // The Length property is us... 阅读全文
posted @ 2015-05-01 22:10 lee0oo0 阅读(297) 评论(0) 推荐(0) 编辑
摘要: 输出语句:///////////////////////////////public class Hello1{ public static void Main() { System.Console.WriteLine("Hello, World!"); }}/////////... 阅读全文
posted @ 2015-05-01 17:32 lee0oo0 阅读(387) 评论(0) 推荐(0) 编辑
摘要: 这几天看到微软的build大会,感觉微软不甘落后他人,曾经的巨头难道又要重新崛起,不管了,为了以后的饭碗,还是简单学习一些c#吧,有时这种紧张感不错的,现在由于这种紧张感,我已经掌握的java(主要弄的是Android),ios,python,html,css,javascript;之前从事的是An... 阅读全文
posted @ 2015-05-01 17:20 lee0oo0 阅读(526) 评论(0) 推荐(0) 编辑
  2015年4月29日
摘要: python之对指定目录文件夹的批量重命名import os,shutil,stringdir = "/Users/lee0oo0/Documents/python/test" #指定的目录for i in os.listdi... 阅读全文
posted @ 2015-04-29 15:16 lee0oo0 阅读(1428) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 ··· 45 下一页