Skip to content

Instantly share code, notes, and snippets.

View soufDev's full-sized avatar

Soufiane AIT AKKACHE soufDev

  • Paris, France
View GitHub Profile
@soufDev
soufDev / Bae.py
Last active September 17, 2017 12:28
Python
class Bae:
"""dtring for Bae"""
much = 1.50 # class variable
students = 0 # we use is class variable to count the number of instances in this classes
def __init__(self, first, last, grade, classement):
self.first = first # These are atributes for the class
self.last = last
self.grade = grade
self.classement = classement
package com.globbiz.v3.repository;
import com.globbiz.v3.domain.User;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.mongodb.repository.MongoRepository;
import org.springframework.data.mongodb.repository.Query;
import java.util.Date;
public void createUsersForTest(int nb, List<String> groupsID) {
for(int i=1; i<=nb ; i++) {
UserDTO userDTO = new UserDTO();
userDTO.setFirstName("firstname"+i);
userDTO.setLastName("lastname"+i);
userDTO.setUsername("username"+i);
userDTO.setPassword("12345678");
Set<String> authority = new HashSet<String>();
authority.add("USER_ROLE");