when I install or check my own R-package using:
devtools::check()
I need to have a configure file in my package. However, it would be useful if R automatically calls autoconf before and then configure. Do you know if this is possible?
答案 0 :(得分:4)
这并不是devtools自己挂钩的R工作流程的一部分。
事实上,open / mostly unanswered proposal我发送了this r-package-devel thread {{3}}。重新生成configure
是另一种可能的用例。
但从狭义上讲,你应该在你调用autoconf
和之前调用configure.ac
之后调用R CMD check
public class Child
{
public string Name { get; set; }
public int Age { get; set; }
}
public partial class MainWindow : Window
{
List<Child> children = new List<Child>();
public MainWindow()
{
InitializeComponent();
}
private void Window_Loaded(object sender, RoutedEventArgs e)
{
children.Add(new Child { Name = "johny", Age = 22 });
children.Add(new Child { Name = "johnsy", Age = 212 });
children.Add(new Child { Name = "johdny", Age = 222 });
pnlChildren.DataContext = children;
}
}
public class AgeValidation : ValidationRule
{
public override ValidationResult Validate(object value, CultureInfo cultureInfo)
{
int age;
if (Int32.TryParse(value.ToString(), out age))
{
if (age >= 3)
{
return new ValidationResult(true, null);
}
}
return new ValidationResult
(false, "Name cannot be more than 3 characters long.");
}
}
(无论你是否通过devtools这样做都没关系。)