[RUBY] Class and model

What is a class

--The concept of ruby --A box (object-oriented) that contains multiple data and processes (methods) together. Something like a blueprint.

What is a model

--The concept of rails ~~ Ruby ~~ --It must be a class, but it always has a table (database) corresponding to the model. --For example, the Post model has a posts table (the table contains multiple data, so the name is in the plural) => On the contrary, the model name must be named in the singular.

Recommended Posts

Class and model
Model and table creation
abstract (abstract class) and interface (interface)
Class and instant part2
java.util.Optional class and null and not null
Java class definition and instantiation
Difference between class and instance
Relationship between package and class
About Ruby and object model
Difference between instance method and class method
Get TypeElement and TypeMirror from Class
Difference between instance variable and class variable
Relationship between database and model (basic)
StringBuffer and StringBuilder Class in Java
Rails model and table naming conventions
Internal class and lambda study notes
Differences between Applet class and JApplet class
Spring with Kotorin --2 RestController and Data Class
== and equals
11th class: Class
[Java] Differences between instance variables and class variables
Anonymous class (anonymous class)
[Java] Inheritance and structure of HttpServlet class
MVC model
Class method
Proper use of interface and abstract class
ObjectMapper class
Java programming (static clauses and "class variables")
ArrayList class
[Java] How to use FileReader class and BufferedReader class
A story that separates business logic and model
About next () and nextLine () of the Scanner class
Java and Swift comparison (3) Class implementation / Class inheritance / Class design
Disassemble and decompile .class files compiled from Kotlin
Ruby: Differences between class methods and instance methods, class variables and instance variables
[Java] How to use Calendar class and Date class