In object-oriented programming (OOP), a method is a function associated with an object and is used to perform operations on that object. When a programmer creates an object to retrieve customer names from a database, the operation that retrieves the names is typically encapsulated in a method. This method might be called something like getCustomerNames() and is responsible for querying the database and returning the results. Reference: Basic concepts of OOP, including objects and methods, are foundational topics in programming and are discussed in CompTIA IT Fundamentals and other programming guides.