A gangster is a criminal who is a member of a gang. The term can also be applied to characters who fit the stereotypical image of a gangster, such as the character who appeared in the holodeck of the starship Enterprise-D in 2370. (TNG: "Emergence")
Aliens acted as gangsters in 2268 on the planet Sigma Iotia II, where a book called "Chicago Mobs of the Twenties" had been left behind by the Federation vessel Horizon. (TOS: "A Piece of the Action")
In the holodeck of the Enterprise-D, Captain Jean-Luc Picard enjoyed participating in simulations which were adapted from stories by Tracy Tormé. These tales included characters such as Dixon Hill, Rex and Nicky the Nose. (TNG: "The Big Goodbye", "Manhunt" and Star Trek: First Contact)
In 2375, several gangsters appeared in the Vic Fontaine holoprogram, as a result of a Jack-in-the-Box becoming active. Added to the program by Vic's creator, Felix, this subroutine caused the characters of Frankie Chalmers, Tony Cicci and Carl Zeemo to appear. These gangsters fired Vic from his lounge, although the crew of Deep Space 9 later helped Vic to regain his position and put an end to the "Jack-in-the-Box". (DS9: "Badda-Bing, Badda-Bang")