给定两个具有一对多关联的ActiveRecord模型,User.rb:
class User < ActiveRecord::Base
has_many :books, foreign_key: "user_id", dependent: :destroy
end
Book.rb:
class Book < ActiveRecord::Base
belongs_to :user, foreign_key: "user_id", dependent: :destroy
end
然后在app.rb中,这个问题就会出现
class Prob
我有以下几点:
class A {
typedef void(A::*Exec)(); //this is for creating a pointer to a void the recives void
void Method(Exec exec) //Here i have 1 void that recives void parameter
{
exec();
}
void SingleProcedure()
{
/* code here */
}
public: